Skip to content

feature: Add environment variables for configuration#196

Open
sweco-semkni wants to merge 5 commits intoorigo-map:masterfrom
sweco-semkni:feature__Add_env_variable_config
Open

feature: Add environment variables for configuration#196
sweco-semkni wants to merge 5 commits intoorigo-map:masterfrom
sweco-semkni:feature__Add_env_variable_config

Conversation

@sweco-semkni
Copy link

@sweco-semkni sweco-semkni commented Dec 16, 2024

Resolves #195

Make it possible to set configuration values with environment variables, as an addition to the configuration values in the config files: dbconfig.js and config.js.

Configuring values in the configuration with environment variables, is useful when running the server in a Kubernetes server environment.

@MattiasSp
Copy link
Contributor

MattiasSp commented Jan 31, 2025

Fixes #195, no? Add a note in the PR description to link the issue :)

@MattiasSp
Copy link
Contributor

It looks like you have excluded all array config options, which makes many of the services still be dependent on the config.js and dbconfig.js files.

Would it be possible to add a simple-ish JSON deserializer to the config utility so that at least some smaller arrays could be entered as strings in environment variables as well?

Also, note that this PR currently does not support changing the database type from e g PostgreSQL (pg) to MS SQL Server (mssql) using environment variables.

I'll try to find time to test it soon-ish :)

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

Successfully merging this pull request may close these issues.

Environment variables for configuration

2 participants