add option for allowing temp edits when using *_CONFIG_FILE env vars
Created by: slimsag
This adds two new environment variables: EXTSVC_CONFIG_ALLOW_EDITS
and
SITE_CONFIG_ALLOW_EDITS
which when true
allow edits to be made to the
external service config and site config even when loading configuration via
a file using EXTSVC_CONFIG_FILE
or SITE_CONFIG_FILE
.
For why someone would want to do this, see #4912 -- in particular this helps a large customer try out options easily before committing them (which involves some downtime as Sourcegraph must restart.) It is also something we do in dev environments today.
The reason I am working on this now is to help a customer debug an issue by setting https://github.com/sourcegraph/sourcegraph/pull/5202 on their instance.
Fixes #4912
Test plan: Manual testing (can't be automatically tested easily) + thoroughly being tested by all devs since it is on in our dev envs. No change for users who don't set the new option, so low risk.