Closed lazyest closed 1 year ago
Can you try to see the setup wizard works fine. Remember to select new installation instead of upgrade.
We cannot support unattended install as that is code delivered by Combodo, so issues regarding to that should be directed to their support portals.
yeah, sure I've tried everything and I'll definitely not publish a post without this ;) yes, I've tried new installation on both 2.7 and 3 images. Same docker-compose, 2.6 is OK, 2.7/3.0 failed
I just ran the setup wizard with the following compose file and it all worked fine:
version: '3'
services:
itop:
image: supervisions/itop:3.0
environment:
VIRTUAL_HOST: itop-test.docker.super-visions.com
DB_ENV_MYSQL_DATABASE: itop
DB_ENV_MYSQL_USER: itop
DB_ENV_MYSQL_PASSWORD: itop
links:
- "db:db"
network_mode: bridge
db:
image: mariadb
environment:
MYSQL_DATABASE: itop
MYSQL_USER: itop
MYSQL_PASSWORD: itop
MYSQL_ALLOW_EMPTY_PASSWORD: 'yes'
network_mode: bridge
It also looks like your itop-config.php
is not having a password anymore?
hm, you right, in this way its working nice. I didn't find available environment variables for image, maybe this is doing the trick internally? Anyhow thanks, seems like problem was solved for now
after successful installation I have
Warning: require_once(/var/www/html/env-production/dictionaries/languages.php): failed to open stream: No such file or directory in /var/www/html/core/metamodel.class.php on line 6613
Fatal error: require_once(): Failed opening required '/var/www/html/env-production/dictionaries/languages.php' (include_path='/var/www/html/lib/pear/archive_tar:/var/www/html/lib/pear/console_getopt:/var/www/html/lib/pear/pear-core-minimal/src:/var/www/html/lib/pear/pear_exception:.:/usr/local/lib/php') in /var/www/html/core/metamodel.class.php on line 6613
seems like if I'm not installing sample data it returns me this kind of result. Will investigate it more but I feel something wrong here
hm in my understanding its seems to conflict with basic http auth of reverse proxy upd: nope
Fatal error: Uncaught CoreException: Include: wrong file name in configuration file: config file = /var/www/html/conf/production/config-itop.php, section = addons, filename = /addons/userrights/userrightsnull.class.inc.php in /var/www/html/core/metamodel.class.php:6814
Stack trace:
#0 /var/www/html/core/metamodel.class.php(6632): MetaModel::IncludeModule('/addons/userrig...', 'addons')
#1 /var/www/html/core/metamodel.class.php(6525): MetaModel::LoadConfig(Object(Config), false)
#2 /var/www/html/setup/runtimeenv.class.inc.php(131): MetaModel::Startup(Object(Config), true, false, false, 'production')
#3 /var/www/html/setup/wizardsteps.class.inc.php(2617): RunTimeEnvironment->InitDataModel(Object(Config), true)
#4 /var/www/html/setup/wizardcontroller.class.inc.php(197): WizStepDone->Display(Object(SetupPage))
#5 /var/www/html/setup/wizardcontroller.class.inc.php(134): WizardController->DisplayStep(Object(WizStepDone))
#6 /var/www/html/setup/wizardcontroller.class.inc.php(270): WizardController->Next()
#7 /var/www/html/setup/ in /var/www/html/core/metamodel.class.php on line 6814
just clicking default installation of production
I’ll try again without env variables and let you know.
The language and other iTop errors don’t seem to be related to the Docker image, so they should be reported with Combodo.
Maybe you can just provide as much info about available variables? ;) I'll play with them
still something unclear with packaging as far as I can see
after finished installation I have
Warning: require_once(/var/www/html/env-production/dictionaries/languages.php): failed to open stream: No such file or directory in /var/www/html/core/metamodel.class.php on line 6613
Fatal error: require_once(): Failed opening required '/var/www/html/env-production/dictionaries/languages.php' (include_path='/var/www/html/lib/pear/archive_tar:/var/www/html/lib/pear/console_getopt:/var/www/html/lib/pear/pear-core-minimal/src:/var/www/html/lib/pear/pear_exception:.:/usr/local/lib/php') in /var/www/html/core/metamodel.class.php on line 6613
All worked fine also without the specific ENV vars and choose the production option instead of the demo sample data, You can see here which env variables are being used.
Do you select any specific language that is causing issues maybe? Do you also have the same problem when installing iTop plain, so without using Docker?
Well
Seems like I've found the explanation
I'm using reverse proxy, traefik Also, there was basic http auth on top of it. This seems to be interfering with itop internals somehow. For now its not very important how, I've switched off auth forwarding in traefik and it seems to resolve issue at least with 3.x branch. So sorry for disturbing but now it can be somehow described for future ;)
Thanks to come back on this. Feel free to share a good working Traefik config!
FYI, I'm using jwilder/nginx-proxy in my dev setup.
sorry but just now I'm a bit confused Image is running, itop is fine. I'm restarting traefik removing basic http auth and have
Warning: require_once(/var/www/html/env-production/dictionaries/languages.php): failed to open stream: No such file or directory in /var/www/html/core/metamodel.class.php on line 6613
Fatal error: require_once(): Failed opening required '/var/www/html/env-production/dictionaries/languages.php' (include_path='/var/www/html/lib/pear/archive_tar:/var/www/html/lib/pear/console_getopt:/var/www/html/lib/pear/pear-core-minimal/src:/var/www/html/lib/pear/pear_exception:.:/usr/local/lib/php') in /var/www/html/core/metamodel.class.php on line 6613
How can it be possible and what kind of magic is happening here? Maybe I should clean something inside for some reason? This is first error I've got but later another one started to appear
I see dictionaries in html dir but not in env-production.
Yeah please clean all volumes and containers and start over completely. Also test with iTop running outside a container or without Traefik. Please also mention which language you select for administrator user.
Language is always EN for now I've recreated whole VM several times so its constant behavior Running without traefik won't require restarting traefik ;)
seems like content of env-production dissapearing after container restart
Wait, what do you mean with "restart"? What exact commands do you use?
If you want to persist volumes during recreation of containers, you need to instruct docker-compose to do that.
ok here we go different ls outputs are from different stages, after docker-compose up, after filling wizard etc
root@itop:/opt/itop# docker-compose exec itop ls env-production
root@itop:/opt/itop# docker-compose exec itop ls env-production
authent-cas combodo-backoffice-darkmoon-theme itop-backup itop-core-update itop-portal itop-storage-mgmt web.config
authent-external combodo-db-tools itop-bridge-cmdb-ticket itop-datacenter-mgmt itop-portal-base itop-structure
authent-ldap combodo-webhook-integration itop-bridge-virtualization-storage itop-endusers-devices itop-profiles-itil itop-themes-compat
authent-local core itop-change-mgmt itop-files-information itop-request-mgmt itop-tickets
autoload.php dictionaries itop-config itop-hub-connector itop-service-mgmt itop-virtualization-mgmt
branding itop-attachments itop-config-mgmt itop-oauth-client itop-sla-computation itop-welcome-itil
root@itop:/opt/itop# docker-compose stop traefik
Stopping itop_traefik_1 ... done
root@itop:/opt/itop# docker-compose exec itop ls env-production
authent-cas combodo-backoffice-darkmoon-theme itop-backup itop-core-update itop-portal itop-storage-mgmt web.config
authent-external combodo-db-tools itop-bridge-cmdb-ticket itop-datacenter-mgmt itop-portal-base itop-structure
authent-ldap combodo-webhook-integration itop-bridge-virtualization-storage itop-endusers-devices itop-profiles-itil itop-themes-compat
authent-local core itop-change-mgmt itop-files-information itop-request-mgmt itop-tickets
autoload.php dictionaries itop-config itop-hub-connector itop-service-mgmt itop-virtualization-mgmt
branding itop-attachments itop-config-mgmt itop-oauth-client itop-sla-computation itop-welcome-itil
root@itop:/opt/itop# nano docker-compose.yml
root@itop:/opt/itop# docker-compose up -d
Starting itop_traefik_1 ...
mariadb is up-to-date
Starting itop_traefik_1 ... done
Recreating itop_itop_1 ... done
root@itop:/opt/itop# docker-compose exec itop ls env-production
I can imagine I need to store something but without description we're discussing it here :) need more docs, you see? :) In fact, I need to mount /var/www/html/env-production as volume, right? Thats the only tricky path to store or we have more to find out later?
definitely not all. I've stored env-production and got
Fatal error: Uncaught CoreException: Include: wrong file name in configuration file: config file = /var/www/html/conf/production/config-itop.php, section = addons, filename = /addons/userrights/userrightsnull.class.inc.php in /var/www/html/core/metamodel.class.php:6814 Stack trace: #0 /var/www/html/core/metamodel.class.php(6632): MetaModel::IncludeModule('/addons/userrig...', 'addons') #1 /var/www/html/core/metamodel.class.php(6529): MetaModel::LoadConfig(Object(Config), true) #2 /var/www/html/application/startup.inc.php(101): MetaModel::Startup('/var/www/html/c...', false, true, false, 'production') #3 /var/www/html/pages/UI.php(299): require_once('/var/www/html/a...') #4 {main} thrown in /var/www/html/core/metamodel.class.php on line 6814
Seems like need also addons dir, right?
What did you modify in docker-compose.yml
causing to the itop container to be recreated?
Recreating containers will always result in losing data, unless the volumes are persisted. That is not something specific to iTop. To see current volumes defined in iTop container: https://github.com/Super-Visions/docker-itop/blob/bdb7a5134b458215a36a7faf346ed93443c243be/3.0/Dockerfile#L45
See docker compose docs on how to configure volumes.
Note that you might also want to persist the database data..
oh, cool. This seems to be proper answer. If you don't mind, plz update the doc for docker image with that 4 path to store somewhere persistently
PS: Of course I'm storing DB, as you've already mentioned, its not specific to iTop :)
Thank you very much, its always good to have so responsive person.
Just started to use itop with your docker images. Few days I've spent on figuring out and now I see 2.7 and 3.0 images are not working as default. From my point thsts something wring with database connection, because on manual installation it shows empty page after wizard steps done and I have in logs
User/pass is working and same docker-compose configuration for 2.6 image is working fine
Also I've tried unattended installation with wiki-provided sampled xml response file, same thing. Maybe I'm wrong but just now I have no another explanation
docker-compose part:
Unattented mode seems to be non-compatible with 3.x in general
docker-compose exec -T -u www-data itop bash -c "cd setup; php install.php --response_file=install.xml --clean=1"
but with 2.7 its running but after we have
Once again, :2.6 image is fine