fix: restore config management support for mapproxinator - #93
Open
roicohen326 wants to merge 1 commit into
Open
Conversation
mapproxinator v1.3.0 adopted @map-colonies/config, which fetches config
over HTTP at startup. The chart sets no CONFIG_* variables, so the library
falls back to its default server URL and the container exits:
ConfigError [httpGeneralError]: connect ECONNREFUSED 127.0.0.1:8080
at async initConfig (/usr/src/app/common/config.js:14:22)
This support existed once. #85 added it on 25 Jun; #86 (the v2.0.0 MapProxy 6
rewrite) removed it a day later, so 2.0.0, 2.1.0 and 2.1.1 all shipped without
it. This restores it in both configmaps - the init container and mapproxinator
use separate ones, and both containers run the same image.
Deviation from #85: version defaults to 'latest', not ''. Verified against
the real image - an empty value fails schema validation:
'version' property must be equal to the allowed value
path: '{base}.version', allowedValue: 'latest'
serverUrl now matches the exporter-trigger convention.
Verified by running mapproxinator:v1.3.0 in-cluster with the rendered env:
config initialization succeeds ("initializing configuration") and the process
proceeds to its normal FS provider step.
Consumers set global.configManagement.offlineMode=true to cover both
containers with one value.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
mapproxinator:v1.3.0adopted@map-colonies/config, which fetches configuration over HTTP at startup. The chart sets noCONFIG_*variables, so the library falls back to its default server URL and the container exits immediately:This is currently crashlooping in qa and integration after the 2.3.1 version alignment bumped mapproxinator to v1.3.0. Neither environment is down — the previous v1.2.5 pods stay up because the new ones never pass readiness.
Cause
This support existed once. #85 added it on 25 Jun. #86 — the v2.0.0 MapProxy 6 rewrite — removed it one day later:
So 2.0.0, 2.1.0 and 2.1.1 all shipped without it. Chart 6.0.1 in
mc-mapproxyis missing it too.Change
Restores the
#85implementation in both configmaps — the init container and mapproxinator use separate ones, and both run the same image, so both need it.One deliberate deviation from #85:
versiondefaults to'latest', not''. Verified against the real image — an empty value fails schema validation:serverUrlnow matches theexporter-triggerconvention (http://localhost:8080/api) rather than''.Defaults are unchanged in effect (
offlineMode: false); consumers opt in.Verification
Rendered env applied to
mapproxinator:v1.3.0running in-cluster:Config init succeeds; the process proceeds to its normal FS provider step and stops only because the throwaway test pod had no
mapproxy.yamlmounted. The chart mounts it in a real deployment.Also verified:
helm lint— 0 failedhelm templaterenders all four keys in both configmapsglobal.configManagement.offlineMode=true(one value covering both containers)Consumer follow-up
helm-chartsthen setsglobal.configManagement.offlineMode: trueunder mapproxy inserving-values.yamland bumps the chart, across master / qa / integration.