Comments (14)
Seems to work now.
I have rebuilded the icingaweb2 directory after removing
I've copied the roles.ini and imported the old DB
This incompatibility seems to be related to the new web2 modules path (old one was /etc/icingaweb2/modules/)
my last
docker run
-e ICINGA2_FEATURE_GRAPHITE=true
-e ICINGA2_FEATURE_GRAPHITE_HOST="graphite.somewhere"
-e ICINGA2_FEATURE_GRAPHITE_PORT=2003
-e ICINGA2_FEATURE_DIRECTOR=true
-e ICINGA_PASSWORD=pass
-e DIRECTOR_PASSWORD=pass
-e IDO_PASSWORD=pass
-e DEBIAN_SYS_MAINT_PASSWORD=pass
-e ICINGAWEB2_ADMIN_USER=icingaadmin
-e ICINGAWEB2_ADMIN_PASS=icinga
-e ICINGAWEB2_PASSWORD=pass
-t jordan/icinga2:latest
from icinga2.
in kickstart.ini the password is changed even if I set DIRECTOR_KICKSTART=false
DIRECTOR_KICKSTART is the wrong variable. ICINGA2_FEATURE_DIRECTOR would be.
Better explanation: kickstart.ini
is needed in general for director to connect to database. DIRECTOR_KICKSTART
only tells the container to make an initial kickstart at the beginning. Setting it to false only stops the initial kickstart.
from icinga2.
What about just emptying your current /etc/icingaweb2
, and dropping the db (docker exec -ti icinga_server-new mysql 'drop database icingaweb2;'
)?
Then start your container with an empty icingaweb2-configuration, let it deploy the clean default and after boot up merge your manual changes back in the new /etc/icingaweb2
.
What about this?
from icinga2.
You have to set ICINGA2_FEATURE_DIRECTOR=false
to prevent rewriting of kickstart.ini.
from icinga2.
look at the readme. We added new variables for the user-interface to set username/password of the default user, etc... Those willl always be respected and therefore they may overwrite previously defined values.
from icinga2.
OK, TY
I have configured the run file with the variables, icinga2 seems to run fine.
icingaweb2 isnt able to login with icingaadmin:admin or with my previous configured clients.
the /etc/icingaweb2 volume is rewrited every time
I can login in mysql with icingaweb user and I see the imported users and group but no authentication
some time i got this error (seems to be that it try to overwrite):
ERROR 1050 (42S01) at line 3: Table 'icingaweb_group' already exists
my run:
docker run -h master \
-p 80:80 -p 443:443 -p 5665:5665 \
--name icinga_server-new \
-v $SRV/etc/icinga2/:/etc/icinga2 \
-v $SRV/etc/icinga-web/:/etc/icinga-web \
-v $SRV/etc/icingaweb2:/etc/icingaweb2 \
-v $SRV/var/log:/var/log \
-v $SRV/etc/icinga2-classicui/:/etc/icinga2-classicui/ \
-v $SRV/var/lib/icinga2:/var/lib/icinga2 \
-v $SRV/etc/ssmtp:/etc/ssmtp \
--link graphite:graphite \
-e TZ=Europe/Rome \
-e ICINGA2_FEATURE_GRAPHITE=true \
-e ICINGA2_FEATURE_GRAPHITE_HOST="graphite" \
-e ICINGA2_FEATURE_GRAPHITE_PORT=2003 \
-e ICINGA_PASSWORD=pass \
-e ICINGAWEB2_PASSWORD=pass \
-e DIRECTOR_PASSWORD=pass \
-e IDO_PASSWORD=pass \
-e DEBIAN_SYS_MAINT_PASSWORD=pass \
-e ICINGAWEB2_ADMIN_USER=adminicinga \
-e ICINGAWEB2_ADMIN_PASS=pass \
-t jordan/icinga2:latest
from icinga2.
Hi @aleliga
That's strange. The icingaweb2 volume should not get overwritten as long as there is at least one file in it.
Are you able to log in using the default icingaadmin:icinga credentials to /icingaweb2 ?
from icinga2.
Hi @jjethwa
no I can't login with any credential, I've tried to set the ADMIN_USER, but without any result.
In the db there are my users (imported from dump) but no ADMIN_USER
when I try to login I got this error
ERROR 1050 (42S01) at line 3: Table 'icingaweb_group' already exists
If I restore old /icingaweb2 (pre upgrade) I've got the "no auth method" message, in the login interface
from icinga2.
@jjethwa I feel we have hit a bug. But I'm not able to reproduce yet.
That's strange. The icingaweb2 volume should not get overwritten as long as there is at least one file in it.
The configuration done via ENV
still will be overwritten. But only the single options and not the full file.
@aleliga Could you please show
/etc/icingaweb2/resources.ini
/etc/icingaweb2/authentication.ini
- the output of
docker exec -ti icinga_server-new mysql icingaweb2 -e 'select * from icingaweb_user;'
from icinga2.
Resources.ini is similar, no "" in the password but seems to work
/etc/icingaweb2/resources.ini
[icingaweb_db]
type = "db"
db = "mysql"
host = "localhost"
port = "3306"
dbname = "icingaweb2"
username = "icingaweb2"
password = pass
prefix = "icingaweb_"
charset =
persistent = "0"
[icinga_ido]
type = "db"
db = "mysql"
host = "localhost"
port = "3306"
dbname = "icinga2idomysql"
username = "icinga2-ido-mysq"
password = pass
charset =
persistent = "0"
[director]
type = "db"
db = "mysql"
host = "localhost"
port = "3306"
dbname = "director"
username = "director"
password = pass
charset = "utf8"
persistent = "0"
/etc/icingaweb2/authentication.ini
[icingaweb2]
backend = "db"
resource = "icingaweb_db"
mysql icingaweb2 -e 'select * from icingaweb_user;'
| olduser1 | 1 | password | 2016-05-13 15:34:28 | NULL |
| olduser1 | 1 | password | 2016-05-13 15:34:28 | NULL |
| API | 1 | password | 2016-05-13 15:34:28 | NULL |
| icingaadmin | 0 | password | NULL | 2016-05-24 14:00:24 |
from icinga2.
Having:
| olduser1 | 1 | password | 2016-05-13 15:34:28 | NULL | | olduser1 | 1 | password | 2016-05-13 15:34:28 | NULL | | API | 1 | password | 2016-05-13 15:34:28 | NULL | | icingaadmin | 0 | password | NULL | 2016-05-24 14:00:24 |
vs
-e ICINGAWEB2_ADMIN_USER=adminicinga \
(Edit) It should be obvious, that your configured user does not match the icingaweb2.icingaweb_user
-table.
Could you also provide full logs of the startup of your container?
from icinga2.
You are right, I've changed user in this container
I've rechanged the default pass to icinga, rebuild with default credentials "icingaadmin:icinga" and imported DB with no results.
Copying icingaweb2/modules/director/kickstart.ini and icingaweb2/resources.ini the container seems to work good, but web2 have the same problem at restart (file are rewrited)
I see these differences in the files:
in kickstart.ini the password is changed even if I set DIRECTOR_KICKSTART=false
in resources.ini passwords doesn't have double quotes "
from icinga2.
You are right, I've changed user in this container
This is valid, supported and perfectly fine. The bogus thing: the user specified in docker run
-statement does not match the DB.
in kickstart.ini the password is changed even if I set DIRECTOR_KICKSTART=false
DIRECTOR_KICKSTART
is the wrong variable. ICINGA2_FEATURE_DIRECTOR
would be.
in resources.ini passwords doesn't have double quotes "
AFAIK, quotes are not needed in ini-format.
Copying icingaweb2/modules/director/kickstart.ini and icingaweb2/resources.ini the container seems to work good, but web2 have the same problem at restart (file are rewrited)
the files are rewritten, but the diff is only the new password. The container generates on every reboot a new password for its DB connections.
from icinga2.
I have make some other try
ICINGA2_FEATURE_DIRECTOR=true
DIRECTOR_KICKSTART=false
director/kickstart.ini is rewrited every time, with a new passwords
In icingaweb2/resources.ini
charset =
break icingaweb2 (in original conf charset="" work), this must to be a problem in the charset = NULL definition
charset = "utf8" or charset = utf8 are OK
from icinga2.
Related Issues (20)
- having issues with mail HOT 3
- Adding Vsphere Module HOT 5
- Cant restart an exited container HOT 11
- Your MySQL Database Server is running currently inside the icinga2 container. In future, the MySQL will be located in a separate container by default. HOT 22
- Corrupt File? HOT 5
- No Graphs from graphite for 12 hours or more (Days, Weeks, Months and Years) HOT 6
- Permissions building the image HOT 2
- Additional App HOT 1
- DockerFile issue: Access denied for user root (using password NO) HOT 16
- have issue with check_http HOT 9
- Director supervisor script should not run when director is disabled HOT 7
- mail notification problem HOT 7
- Environment variable to specify icinga2 `log-level` HOT 7
- Class 'Icinga\Util\Translator' not found HOT 4
- permission error on /var/cache/icinga2 folder under Windows HOT 1
- Weird behaviour when mounting /etc/icinga2/* HOT 8
- Errors after upgrade HOT 2
- Documentation mismatch HOT 1
- Dockerfile: deb http://packages.icinga.org/debian does not exist anymore (?) HOT 2
- MySQL user 'root' has no password HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from icinga2.