Skip to content

Commit f566b49

Browse files
committed
fix: using a more simplified template pattern
1 parent 6902a2a commit f566b49

File tree

5 files changed

+10
-10
lines changed

5 files changed

+10
-10
lines changed

drydock/patches/caddyfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
}
3333
route @scorm_matcher {
3434
uri /scorm-proxy/* strip_prefix /scorm-proxy
35-
reverse_proxy https://{{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }} {
36-
header_up Host {{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }}
35+
reverse_proxy https://{{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }} {
36+
header_up Host {{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }}
3737
}
3838
}
3939
{% endif %}

drydock/patches/caddyfile-cms

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ route @scorm_matcher {
1414
}
1515
route @scorm_matcher {
1616
uri /scorm-proxy/* strip_prefix /scorm-proxy
17-
reverse_proxy https://{{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }} {
18-
header_up Host {{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }}
17+
reverse_proxy https://{{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }} {
18+
header_up Host {{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }}
1919
}
2020
}
2121
{% endif %}

drydock/patches/caddyfile-lms

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ route @scorm_matcher {
1414
}
1515
route @scorm_matcher {
1616
uri /scorm-proxy/* strip_prefix /scorm-proxy
17-
reverse_proxy https://{{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }} {
18-
header_up Host {{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }}
17+
reverse_proxy https://{{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }} {
18+
header_up Host {{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }}
1919
}
2020
}
2121
{% endif %}

drydock/templates/drydock/k8s/ingress/cms.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ metadata:
1414
proxy_http_version 1.1;
1515
proxy_set_header Connection "";
1616
proxy_set_header Authorization '';
17-
proxy_set_header Host {% if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }}{%- endif %};
17+
proxy_set_header Host {% if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }}{%- endif %};
1818
proxy_hide_header x-amz-id-2;
1919
proxy_hide_header x-amz-request-id;
2020
proxy_hide_header x-amz-meta-server-side-encryption;
@@ -24,7 +24,7 @@ metadata:
2424
proxy_intercept_errors on;
2525
add_header Cache-Control max-age=31536000;
2626
rewrite /scorm-proxy(.*) $1 break;
27-
proxy_pass https://{%- if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }}{%- endif %};
27+
proxy_pass https://{%- if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }}{%- endif %};
2828
}
2929
{%- endif %}
3030
spec:

drydock/templates/drydock/k8s/ingress/lms.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ metadata:
1414
proxy_http_version 1.1;
1515
proxy_set_header Connection "";
1616
proxy_set_header Authorization '';
17-
proxy_set_header Host {% if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }}{%- endif %};
17+
proxy_set_header Host {% if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }}{%- endif %};
1818
proxy_hide_header x-amz-id-2;
1919
proxy_hide_header x-amz-request-id;
2020
proxy_hide_header x-amz-meta-server-side-encryption;
@@ -24,7 +24,7 @@ metadata:
2424
proxy_intercept_errors on;
2525
add_header Cache-Control max-age=31536000;
2626
rewrite /scorm-proxy(.*) $1 break;
27-
proxy_pass https://{%- if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST|default('s3.amazonaws.com', true) }}{%- endif %};
27+
proxy_pass https://{%- if MINIO_HOST is defined %}{{ MINIO_HOST }}{% else %}{{ S3_STORAGE_BUCKET }}.{{ S3_HOST or 's3.amazonaws.com' }}{%- endif %};
2828
}
2929
{%- endif %}
3030
spec:

0 commit comments

Comments
 (0)