linuxserver / docker-grocy

A container for grocy - the ERP application for your kitchen https://grocy.info
GNU General Public License v3.0
333 stars 44 forks source link

Grocy not configurable with Environment Variables #12

Closed JoschaMiddendorf closed 3 years ago

JoschaMiddendorf commented 5 years ago

linuxserver.io

UnRaid ![Bildschirmfoto 2019-07-04 um 00 17 33](https://user-images.githubusercontent.com/19818109/60628327-47df3380-9df1-11e9-918d-81a13788e883.png) The grocy application can be configured by Environmetnt variables, seeconfig.php. > An environment variable with the same name as the setting and prefix "GROCY_" > so for example "GROCY_BASE_URL" That doesn't work with this container, see screensot above.
BastienVH commented 4 years ago

Apparently the official grocy docker container should be able to use the GROCY_CULTURE env variable to set language, but the container is a few months old now and I can't get it to start up properly on my OpenMediaVault install. Is there something of use in that repo that could help enable env variables in the linuxserver/grocy repo?

mrask90 commented 4 years ago

Would be nice to be able to change the language, when Grocy supports it.

notDavid commented 4 years ago

@mrask90 fyi you can already change the language, after starting the container go to the config folder on the host and open config/data/config.php to change the CULTURE setting. Then stop/start the container.

mrask90 commented 4 years ago

@mrask90 fyi you can already change the language, after starting the container go to the config folder on the host and open config/data/config.php to change the CULTURE setting. Then stop/start the container.

Thanks!

github-actions[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

samirerraji commented 3 years ago

Environment variable seems to work ok with my fresh install on hassio.

hanzZzZzZ commented 3 years ago

I had to add clear_env = no under the [www] pool section in /config/php/www2.conf, otherwise environment variables from Docker are not visible in PHP FPM processes

homerr commented 3 years ago

This seems quite niche with little work arounds, the general configuration of the container works OK so I'll close this one out. If somebody has suggestions on how the functionality could/should be modified, a new issue should be opened with the desired outcomes.

Germs2004 commented 3 years ago

Can this problem be fixed in the docker image by including the clear_env = no code that hanzZzZzZ provided? Adding that one line to my www2 file fixed this problem for me too, so I think LinuxServer/Grocy should include it in everyone's www2 file by default.

jamesanderson9182 commented 6 months ago

I had to add clear_env = no under the [www] pool section in /config/php/www2.conf, otherwise environment variables from Docker are not visible in PHP FPM processes

I tried this and it worked. Perhaps one to add to documenation if new installs don't have this setting automatially. I needed this to set a lot of feature flag settings.