Closed juananpc closed 2 years ago
Hi! You have to specify the mysql connection params in the setup wizard form during the iTop installation process after creating the container. So env vars cannot be used in this context. But you can use internal mysql hostname/container name which resolves from the itop container.
If you have already installed itop and/or have the config file to be mounted to the container (as volume), you can try to specify the necessary params in the config using env vars like this: 'db_host' => $_ENV['ITOP_DB_HOST'],
and then create the itop container and set the env values using -e ITOP_DB_HOST=mysql-hostname
etc. In this case you must not use the web config editor because it will evaluate and substitute the env vars with the values every time you save.
Also take a look at this: https://www.itophub.io/wiki/page?id=2_7_0%3Arelease%3A2_7_whats_new#variables_in_configuration.
Hello!
How can I connect a mysql container to the iTop container? If I run both on the same network, is it possible to use environment variables when running the iTop container? For example: -e DB_HOST=... -e DB_USER=... -e DB_PASSWORD=... -e DB_NAME=...
Thank you very much!