Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to set email addresses via environment variables #7

Open
sean-mcgimpsey opened this issue Oct 10, 2019 · 5 comments
Open

Unable to set email addresses via environment variables #7

sean-mcgimpsey opened this issue Oct 10, 2019 · 5 comments

Comments

@sean-mcgimpsey
Copy link

Trying to automate the deployment of matomo, noticing that the following variables do not work.

MATOMO_GENERAL_LOGIN_PASSWORD_RECOVERY_EMAIL_ADDRESS
MATOMO_GENERAL_LOGIN_PASSWORD_RECOVERY_EMAIL_NAME
MATOMO_GENERAL_NOREPLY_EMAIL_ADDRESS

as well as all Mail settings, which has already been raised.

@tsteur
Copy link
Member

tsteur commented Oct 10, 2019

I don't have a setup right now to test this. But do you know what is exactly not working or why? Is it not reading any values from it at all or is it not correctly encoded?

@sean-mcgimpsey
Copy link
Author

Even though the environment variables are correctly set, the config.ini.php is not being updated with the values, they are completely ignored.

@tsteur
Copy link
Member

tsteur commented Oct 13, 2019

The config.ini.php shouldn't necessarily be updated with these values when you set these environment variables. They would currently only be updated if you make some other changes that trigger a "config save" such as changing the list of trusted hosts in General Settings.

These settings are applied on demand so it doesn't mean it's not working when you don't see the changes there.

@sean-mcgimpsey
Copy link
Author

Ok, but even though the environment variables are set (have confirmed that they are set by echoing), they are not respected by the application. The from addresses are not updated to the value of the env var.
I've tested this on a fresh install.

@tsteur
Copy link
Member

tsteur commented Oct 14, 2019

I've looked through the code and this should work. Not sure where you echoed when testing. Can you do this here https://github.com/matomo-org/plugin-EnvironmentVariables/blob/3.0.0/config/config.php#L23 and also check if it goes into that if?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants