-
Notifications
You must be signed in to change notification settings - Fork 6
docs(envvars): Automatically update environment files #218
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
Open
samoehlert
wants to merge
9
commits into
main
Choose a base branch
from
topic/soehlert/env_var_documentation
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
a22fe3b
fix(naming): use the updated makefile target name
samoehlert 56b9ded
refactor(merge): bring in main to fix the pkg_resources failures
samoehlert efa9aca
refactor(ignore): dont bring in env vars from test files, it just mud…
samoehlert 4ed43bb
fix(comments): remove ugly comments that were picked up
samoehlert 599bcd6
style(ruff): idk formatting stuff
samoehlert 0829078
fix(regex): we were missing a capture group so it always returned Non…
samoehlert 4ffc13f
fix(typo): accidentally deleted a
samoehlert ee7c063
refactor(env choosing): use a more robust method for discovering envi…
samoehlert 5dbf07a
refactor(tests): the order of the map matters. we were catching the t…
samoehlert File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,4 @@ | ||
| --- | ||
|
|
||
| services: | ||
| django: | ||
| build: | ||
|
|
||
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,76 +1,50 @@ | ||
| ## Environment Variables to Set for Deployment | ||
| [comment]: # Which branch of SCRAM to use (you probably want to set it to a release tag) | ||
| scram_code_branch: | ||
| #### Systems | ||
| [comment]: # Email of the main admin | ||
| scram_manager_email: | ||
| [comment]: # Set to true for production mode; set to false to set up the compose.override.local.yml stack | ||
| scram_prod: true | ||
| [comment]: # Set to true if you want ansible to install a scram user | ||
| scram_install_user: true | ||
| [comment]: # What group to put `scram` user in | ||
| scram_group: 'scram' | ||
| [comment]: # What username to use for `scram` user | ||
| scram_user: '' | ||
| [comment]: # WHat uid to use for `scram` user | ||
| scram_uid: '' | ||
| [comment]: # What directory to use for base of the repo | ||
| scram_home: '/usr/local/scram' | ||
| [comment]: # IP or DNS record for your postgres host | ||
| scram_postgres_host: | ||
| [comment]: # What postgres user to use | ||
| scram_postgres_user: '' | ||
| # Environment Variables Reference | ||
|
|
||
| #### Authentication | ||
| [comment]: # This chooses if you want to use oidc or local accounts. This can be local or oidc only. Default: `local` | ||
| scram_auth_method: "local" | ||
| [comment]: # This client id (username) for your oidc connection. Only need to set this if you are trying to do oidc. | ||
| scram_oidc_client_id: | ||
| To update, run `make update-env-docs`. | ||
|
|
||
| #### Networking | ||
| [comment]: # What is the peering interface docker uses for gobgp to talk to the router | ||
| scram_peering_iface: 'ens192' | ||
| [comment]: # The v6 network of your peering connection | ||
| scram_v4_subnet: '10.0.0.0/24' | ||
| [comment]: # The v4 IP of the peering connection for the router side | ||
| scram_v4_gateway: '10.0.0.1' | ||
| [comment]: # The v4 IP of the peering connection for gobgp side | ||
| scram_v4_address: '10.0.0.2' | ||
| [comment]: # The v6 network of your peering connection | ||
| scram_v6_subnet: '2001:db8::/64' | ||
| [comment]: # The v6 IP of the peering connection for the router side | ||
| scram_v6_gateway: '2001:db8::2' | ||
| [comment]: # The v6 IP of the peering connection for the gobgp side | ||
| scram_v6_address: '2001:db8::3' | ||
| [comment]: # The AS you want to use for gobgp | ||
| scram_as: | ||
| [comment]: # A string representing your gobgp instance. Often seen as the local IP of the gobgp instance | ||
| scram_router_id: | ||
| [comment]: # | ||
| scram_peer_as: | ||
| [comment]: # The AS you want to use for gobgp side (can this be the same as `scram_as`?) | ||
| scram_local_as: | ||
| [comment]: # The fqdn of the server hosting this - to be used for nginx | ||
| scram_nginx_host: | ||
| [comment]: # List of allowed hosts per the django setting "ALLOWED_HOSTS". This should be a list of strings in shell | ||
| [comment]: # `django` is required for the websockets to work | ||
| [comment]: # Our Ansible assumes `django` + `scram_nginx_host` | ||
| scram_django_allowed_hosts: "django" | ||
| [comment]: # The fqdn of the server hosting this - to be used for nginx | ||
| scram_server_alias: | ||
| [comment]: # Do you want to set an md5 for authentication of bgp | ||
| scram_bgp_md5_enabled: false | ||
| [comment]: # The neighbor config of your gobgp config | ||
| scram_neighbors: | ||
| [comment]: # The v6 address of your neighbor | ||
| - neighbor_address: 2001:db8::2 | ||
| [comment]: # This is a v6 address so don't use v4 | ||
| ipv4: false | ||
| [comment]: # This is a v6 address so use v6 | ||
| ipv6: true | ||
| [comment]: # The v4 address of your neighbor | ||
| - neighbor_address: 10.0.0.200 | ||
| [comment]: # This is a v4 address so use v4 | ||
| ipv4: true | ||
| [comment]: # This is a v4 address so don't use v6 | ||
| ipv6: false | ||
| | Variable | Service | Environments | Default | file | Description | | ||
| | --- | --- | --- | --- | --- | --- | | ||
| | `CELERY_BEAT_REPLICAS` | Compose | Unknown | 0 | [compose.yml](file://compose.yml) | - | | ||
| | `CELERY_WORKER_REPLICAS` | Compose | Unknown | 0 | [compose.yml](file://compose.yml) | - | | ||
| | `DEBUG` | Compose | Local | - | [compose.override.local.yml](file://compose.override.local.yml), [compose.override.yml](file://compose.override.yml) | This can be set to either `debugpy` or `pycharm-pydevd` currently | | ||
| | `DJANGO_REPLICAS` | Compose | Unknown | 1 | [compose.yml](file://compose.yml) | - | | ||
| | `DOCS_PORT` | Compose | Local | 8888 | [compose.override.local.yml](file://compose.override.local.yml), [compose.override.yml](file://compose.override.yml) | - | | ||
| | `FLOWER_REPLICAS` | Compose | Unknown | 0 | [compose.yml](file://compose.yml) | - | | ||
| | `GOBGP_REPLICAS` | Compose | Unknown | 1 | [compose.yml](file://compose.yml) | - | | ||
| | `HOSTNAME` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `POSTGRES_ENABLED` | Compose | Multiple | 1 | [compose.override.local.yml](file://compose.override.local.yml), [compose.override.production.yml](file://compose.override.production.yml), [compose.override.yml](file://compose.override.yml), [compose.yml](file://compose.yml) | - | | ||
| | `REDIS_REPLICAS` | Compose | Unknown | 1 | [compose.yml](file://compose.yml) | - | | ||
| | `SCRAM_PEERING_IFACE` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `SCRAM_V4_ADDRESS` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `SCRAM_V4_GATEWAY` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `SCRAM_V4_SUBNET` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `SCRAM_V6_ADDRESS` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `SCRAM_V6_GATEWAY` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `SCRAM_V6_SUBNET` | Compose | Production | - | [compose.override.production.yml](file://compose.override.production.yml) | - | | ||
| | `TRANSLATOR_REPLICAS` | Compose | Unknown | 1 | [compose.yml](file://compose.yml) | - | | ||
| | `CONN_MAX_AGE` | Django | Production | 60 | [config/settings/production.py](file://config/settings/production.py) | noqa F405 | | ||
| | `DATABASE_URL` | Django | Common | - | [config/settings/base.py](file://config/settings/base.py), [config/settings/production.py](file://config/settings/production.py) | DATABASES https docs.djangoproject.com/en/dev/ref/settings databases | | ||
| | `DEBUG` | Django | Unknown | - | [config/asgi.py](file://config/asgi.py) | Here we setup a debugger if this is desired. This obviously should not be run in production | | ||
| | `DJANGO_ADMIN_URL` | Django | Production | - | [config/settings/production.py](file://config/settings/production.py) | ADMIN Django Admin URL regex | | ||
| | `DJANGO_ALLOWED_HOSTS` | Django | Production | ["django"] | [config/settings/production.py](file://config/settings/production.py) | https docs.djangoproject.com/en/dev/ref/settings allowed-hosts | | ||
| | `DJANGO_DEFAULT_FROM_EMAIL` | Django | Production | "SCRAM <noreply@es.net>" | [config/settings/production.py](file://config/settings/production.py) | EMAIL https docs.djangoproject.com/en/dev/ref/settings default-from-email | | ||
| | `DJANGO_EMAIL_BACKEND` | Django | Common | "django.core.mail.backends.console.EmailBackend" | [config/settings/base.py](file://config/settings/base.py), [config/settings/local.py](file://config/settings/local.py) | EMAIL https docs.djangoproject.com/en/dev/ref/settings email-backend | | ||
| | `DJANGO_EMAIL_SUBJECT_PREFIX` | Django | Production | "[SCRAM]" | [config/settings/production.py](file://config/settings/production.py) | https docs.djangoproject.com/en/dev/ref/settings email-subject-prefix | | ||
| | `DJANGO_READ_DOT_ENV_FILE` | Django | Common | False | [config/settings/base.py](file://config/settings/base.py) | - | | ||
| | `DJANGO_SECURE_CONTENT_TYPE_NOSNIFF` | Django | Production | True | [config/settings/production.py](file://config/settings/production.py) | https docs.djangoproject.com/en/dev/ref/middleware x-content-type-options-nosniff | | ||
| | `DJANGO_SECURE_HSTS_INCLUDE_SUBDOMAINS` | Django | Production | True | [config/settings/production.py](file://config/settings/production.py) | https docs.djangoproject.com/en/dev/ref/settings secure-hsts-include-subdomains | | ||
| | `DJANGO_SECURE_HSTS_PRELOAD` | Django | Production | True | [config/settings/production.py](file://config/settings/production.py) | https docs.djangoproject.com/en/dev/ref/settings secure-hsts-preload | | ||
| | `DJANGO_SECURE_SSL_REDIRECT` | Django | Production | True | [config/settings/production.py](file://config/settings/production.py) | https docs.djangoproject.com/en/dev/ref/settings secure-ssl-redirect | | ||
| | `DJANGO_SERVER_EMAIL` | Django | Production | DEFAULT_FROM_EMAIL | [config/settings/production.py](file://config/settings/production.py) | https docs.djangoproject.com/en/dev/ref/settings server-email | | ||
| | `DJANGO_SETTINGS_MODULE` | Django | Unknown | "config.settings.local" | [config/asgi.py](file://config/asgi.py), [config/wsgi.py](file://config/wsgi.py) | If DJANGO_SETTINGS_MODULE is unset, default to the local settings | | ||
| | `OIDC_RP_CLIENT_ID` | Django | Common | - | [config/settings/base.py](file://config/settings/base.py) | - | | ||
| | `OIDC_RP_CLIENT_SECRET` | Django | Common | - | [config/settings/base.py](file://config/settings/base.py) | - | | ||
| | `POSTGRES_SSL` | Django | Production | True | [config/settings/production.py](file://config/settings/production.py) | - | | ||
| | `REDIS_HOST` | Django | Common | "redis" | [config/settings/base.py](file://config/settings/base.py) | - | | ||
| | `REDIS_URL` | Django | Production | - | [config/settings/production.py](file://config/settings/production.py) | - | | ||
| | `SCRAM_AUTH_METHOD` | Django | Common | "local" | [config/settings/base.py](file://config/settings/base.py) | Are you using local passwords or oidc? | | ||
| | `USE_DOCKER` | Django | Local | "no" | [config/settings/local.py](file://config/settings/local.py) | - | | ||
| | `DJANGO_SETTINGS_MODULE` | Other | Unknown | "config.settings.local" | [manage.py](file://manage.py) | - | | ||
| | `DEBUG` | Translator | Production | - | [translator/src/translator/translator.py](file://translator/src/translator/translator.py) | Here we setup a debugger if this is desired. This obviously should not be run in production | | ||
| | `SCRAM_EVENTS_URL` | Translator | Production | "ws://django:8000/ws/route_manager/translator_block/" | [translator/src/translator/translator.py](file://translator/src/translator/translator.py) | - | | ||
| | `SCRAM_HOSTNAME` | Translator | Production | "scram_hostname_not_set" | [translator/src/translator/translator.py](file://translator/src/translator/translator.py) | Must match the URL in asgi.py, and needs a trailing slash | |
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.