Skip to content

Commit

Permalink
fix: address PR suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
Ian2012 committed Jun 14, 2024
1 parent ebe34ec commit dff3be0
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 13 deletions.
13 changes: 13 additions & 0 deletions .github/environments/enabled/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,16 @@ DRYDOCK_PDB_MINAVAILABLE_PERCENTAGE_LMS_WORKER: 50
DRYDOCK_PDB_MINAVAILABLE_PERCENTAGE_CMS: 50
DRYDOCK_PDB_MINAVAILABLE_PERCENTAGE_CMS_WORKER: 50
DRYDOCK_MIGRATE_FROM: 13
NGINX_STATIC_CACHE_CONFIG:
lms:
host: {{LMS_HOST}}
path: /static/
port: 8000
cms:
host: {{CMS_HOST}}
path: /static/
port: 8000
mfe:
host: {{MFE_HOST}}
path: /static/
port: 8000
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ The following configuration options are available:
- `DRYDOCK_ENABLE_SENTRY`: Whether to enable sentry. Defaults to `true`.
- `DRYDOCK_SENTRY_DSN`: The sentry DSN. Defaults to `""`.
- `DRYDOCK_POD_LIFECYCLE`: Whether to enable pod lifecycle. Defaults to `true`.
- `NGINX_STATIC_CACHE_CONFIG`: A list of dictionaries with settings for different services to cache their assets in NGINX.
- `DRYDOCK_PDB_MINAVAILABLE_PERCENTAGE_MFE`: The minimum available percentage for the MFE's PodDisruptionBudget. To disable the PodDisruptionBudget, set `0`. Defaults to `0`.
- `DRYDOCK_PDB_MINAVAILABLE_PERCENTAGE_FORUM`: The minimum available percentage for the FORUM's PodDisruptionBudget. To disable the PodDisruptionBudget, set `0`. Defaults to `0`.
- `DRYDOCK_PDB_MINAVAILABLE_PERCENTAGE_CADDY`: The minimum available percentage for the CADDY's PodDisruptionBudget. To disable the PodDisruptionBudget, set `0`. Defaults to `0`.
Expand Down
2 changes: 1 addition & 1 deletion drydock/patches/kustomization-resources
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
- plugins/drydock/k8s/ingress/cms.yml
- plugins/drydock/k8s/ingress/mfe.yml
- plugins/drydock/k8s/ingress/extra-hosts.yml
{% if DRYDOCK_NGINX_STATIC_CACHE_CONFIG %}- plugins/drydock/k8s/ingress/static-cache.yml{%- endif %}
- plugins/drydock/k8s/ingress/static-cache.yml
{%- endif %}
{% if DRYDOCK_DEBUG -%}
- plugins/drydock/k8s/debug/deployments.yml
Expand Down
13 changes: 1 addition & 12 deletions drydock/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,18 +162,7 @@ def get_sync_waves_for_resource(resource_name: str) -> SYNC_WAVES_ORDER_ATTRS_TY
"lms-worker",
"cms-worker",
],
"NGINX_STATIC_CACHE_CONFIG": {
"lms": {
"host": "{{ LMS_HOST }}",
"path": "/static/",
"port": 8000,
},
"cms": {
"host": "{{ CMS_HOST }}",
"path": "/static/",
"port": 8000,
},
},
"NGINX_STATIC_CACHE_CONFIG": {},
},
# Add here settings that don't have a reasonable default for all users. For
# instance: passwords, secret keys, etc.
Expand Down

0 comments on commit dff3be0

Please sign in to comment.