Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .platform/schema
Original file line number Diff line number Diff line change
@@ -1 +1 @@
19
20
599 changes: 363 additions & 236 deletions composer.lock

Large diffs are not rendered by default.

107 changes: 96 additions & 11 deletions conf/cmi/csp.settings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,24 +16,43 @@ report-only:
- 'https://coh-chat-app-prod.ow6i4n9pdzm.eu-de.codeengine.appdomain.cloud'
- 'https://*.hel.fi'
- 'https://coh-chat-app-test.mo1wrhhyog0.eu-de.codeengine.appdomain.cloud'
- 'https://data.reactandshare.com'
- 'https://webanalytics.digiaiiris.com'
- 'https://*.askem.com'
- 'https://*.siteimprove.com'
- 'https://connect.facebook.net'
- 'https://hel.humany.net'
- 'https://wds.ace.teliacompany.com'
- 'https://chat.ace.teliacompany.net'
- 'https://api.ace.teliacompany.net'
img-src:
base: self
base: any
sources:
- 'data:'
- '*.blob.core.windows.net'
- 'https://coh-chat-app-prod.ow6i4n9pdzm.eu-de.codeengine.appdomain.cloud'
- 'https://*.hel.fi'
- 'https://coh-chat-app-test.mo1wrhhyog0.eu-de.codeengine.appdomain.cloud'
- 'https://data.reactandshare.com'
script-src:
base: self
flags:
- report-sample
- unsafe-inline
- unsafe-eval
- wasm-unsafe-eval
sources:
- 'https://coh-chat-app-prod.ow6i4n9pdzm.eu-de.codeengine.appdomain.cloud'
- 'https://*.hel.fi'
- 'https://coh-chat-app-test.mo1wrhhyog0.eu-de.codeengine.appdomain.cloud'
- 'https://cdn.reactandshare.com'
- 'https://data.reactandshare.com'
- 'https://*.askem.com'
- 'https://webanalytics.digiaiiris.com'
- 'https://connect.facebook.net'
- 'https://wds.ace.teliacompany.com'
- 'https://e.infogram.com'
style-src:
base: self
flags:
- report-sample
script-src-elem:
base: self
flags:
- report-sample
Expand All @@ -42,23 +61,86 @@ report-only:
- 'https://coh-chat-app-prod.ow6i4n9pdzm.eu-de.codeengine.appdomain.cloud'
- 'https://*.hel.fi'
- 'https://coh-chat-app-test.mo1wrhhyog0.eu-de.codeengine.appdomain.cloud'
style-src-elem:
- 'https://hel.humany.net'
- 'https://wds.ace.teliacompany.com'
font-src:
base: self
flags:
- report-sample
- unsafe-inline
sources:
- 'https://coh-chat-app-prod.ow6i4n9pdzm.eu-de.codeengine.appdomain.cloud'
- 'https://*.hel.fi'
- 'https://coh-chat-app-test.mo1wrhhyog0.eu-de.codeengine.appdomain.cloud'
font-src:
- 'https://hel.humany.net'
- 'https://makasiini.hel.ninja'
- 'https://ace-knowledge-cdn.teliacompany.net'
frame-src:
base: self
sources:
- palvelukartta.hel.fi
- 'https://coh-chat-app-prod.ow6i4n9pdzm.eu-de.codeengine.appdomain.cloud'
- 'https://*.hel.fi'
- 'https://coh-chat-app-test.mo1wrhhyog0.eu-de.codeengine.appdomain.cloud'
- 'https://*.siteimprove.com'
- 'https://*.userneeds.com'
- 'https://agreeable-island-03e85b803.azurestaticapps.net'
- 'https://*.hotjar.com'
- 'https://coh-chat-app-ibm.eu-de.mybluemix.net'
- 'https://coh-chat-app-prod-ibm.eu-de.mybluemix.net'
- 'https://suite.icareus.com'
- 'https://*.helsinkikanava.fi'
- 'https://*.youtube.com'
- 'https://*.youtu.be'
- 'https://*.facebook.com'
- 'https://*.twitter.com'
- 'https://*.linkedin.com'
- 'https://*.readspeaker.com'
- 'https://*.vimeo.com'
- 'https://*.google.com'
- 'https://*.siteimproveanalytics.com'
- 'https://*.snoobi.com'
- 'https://*.dreambroker.com'
- 'https://youtu.be'
- 'https://dreambroker.com'
- 'https://pollev.com'
- 'https://e.infogram.com'
- 'https://infogram.com'
- 'https://tyoterveys-helsinki-pv.mail-eur.net'
- 'https://walls.io'
- 'https://*.youtube-nocookie.com'
- 'https://*.flockler.com'
- 'https://*.lightwidget.com'
- 'https://hel-thk-botti.kuurahealth.com'
- 'https://*.giosg.com'
- 'https://*.giosgusercontent.com'
- 'https://helfi.fi1.frosmo.com'
- 'https://survey.feedbackly.com'
- 'https://survey.userneeds.com'
- 'https://*.powerbi.com'
- 'https://coh-chat-app-test.eu-de.mybluemix.net'
- 'https://coh-chat-app-dev.eu-de.mybluemix.net'
- 'https://coh-chat-app-prod.eu-de.mybluemix.net'
- 'https://hkp.maanmittauslaitos.fi'
- 'https://reittiopas.hsl.fi'
- 'https://players.icareus.com'
- 'https://wds.ace.teliacompany.com'
- 'https://events.icareus.com'
object-src:
base: self
sources:
- palvelukartta.hel.fi
- 'https://*.youtube-nocookie.com'
- 'https://*.youtube.com'
- 'https://*.youtu.be'
- 'https://*.vimeo.com'
- 'https://suite.icareus.com'
- 'https://players.icareus.com'
- 'https://events.icareus.com'
- 'https://*.helsinkikanava.fi'
media-src:
base: self
sources:
- 'data:'
reporting:
plugin: raven
plugin: none
enforce:
enable: true
directives:
Expand All @@ -72,6 +154,7 @@ enforce:
- 'https://*.vimeo.com'
- 'https://suite.icareus.com'
- 'https://players.icareus.com'
- 'https://events.icareus.com'
- 'https://*.helsinkikanava.fi'
frame-src:
base: self
Expand Down Expand Up @@ -103,6 +186,7 @@ enforce:
- 'https://dreambroker.com'
- 'https://pollev.com'
- 'https://e.infogram.com'
- 'https://infogram.com'
- 'https://tyoterveys-helsinki-pv.mail-eur.net'
- 'https://walls.io'
- 'https://*.youtube-nocookie.com'
Expand All @@ -122,5 +206,6 @@ enforce:
- 'https://reittiopas.hsl.fi'
- 'https://players.icareus.com'
- 'https://wds.ace.teliacompany.com'
- 'https://events.icareus.com'
reporting:
plugin: raven
8 changes: 4 additions & 4 deletions conf/cmi/language/fi/views.view.helfi_redirect.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ display:
is_custom:
expose:
label: 'Käyttäjän luoma'
status:
enabled:
expose:
label: Julkaistu
label: Käytössä
exposed_form:
options:
submit_button: Suodata
Expand Down Expand Up @@ -66,8 +66,8 @@ display:
is_custom:
label: 'Käyttäjän luoma'
separator: ', '
status:
label: Julkaistu
enabled:
label: Käytössä
separator: ', '
empty:
area_text_custom:
Expand Down
8 changes: 4 additions & 4 deletions conf/cmi/language/sv/views.view.helfi_redirect.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ display:
is_custom:
expose:
label: Användarskapad
status:
enabled:
expose:
label: Publicerad
label: Aktiverad
exposed_form:
options:
submit_button: Filtrera
Expand Down Expand Up @@ -66,8 +66,8 @@ display:
is_custom:
label: Användarskapad
separator: ', '
status:
label: Publicerad
enabled:
label: Aktiverad
separator: ', '
empty:
area_text_custom:
Expand Down
34 changes: 17 additions & 17 deletions conf/cmi/views.view.helfi_redirect.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dependencies:
- redirect
- user
_core:
default_config_hash: tH9tiLAhaR2LdCQkjUf5FTsU-8Adc_4pBxrNJPtBKL4
default_config_hash: OOTz1kUCar9ntcNS2WMRD5a3gbGWhjlYpi2GrjWjD8Y
id: helfi_redirect
label: Redirect
module: views
Expand Down Expand Up @@ -224,17 +224,17 @@ display:
multi_type: separator
separator: ', '
field_api_classes: false
status:
id: status
enabled:
id: enabled
table: redirect
field: status
field: enabled
relationship: none
group_type: group
admin_label: ''
entity_type: redirect
entity_field: status
entity_field: enabled
plugin_id: field
label: Published
label: Enabled
exclude: false
alter:
alter_text: false
Expand Down Expand Up @@ -278,7 +278,7 @@ display:
click_sort_column: value
type: boolean
settings:
format: default
format: unicode-yes-no
format_custom_false: ''
format_custom_true: ''
group_column: value
Expand Down Expand Up @@ -682,29 +682,29 @@ display:
default_group: All
default_group_multiple: { }
group_items: { }
status:
id: status
enabled:
id: enabled
table: redirect
field: status
field: enabled
relationship: none
group_type: group
admin_label: ''
entity_type: redirect
entity_field: status
entity_field: enabled
plugin_id: boolean
operator: '='
value: '1'
group: 1
exposed: true
expose:
operator_id: ''
label: Published
label: Enabled
description: ''
use_operator: false
operator: status_op
operator: enabled_op
operator_limit_selection: false
operator_list: { }
identifier: status
identifier: enabled
required: false
remember: false
multiple: false
Expand Down Expand Up @@ -747,7 +747,7 @@ display:
redirect_redirect__uri: redirect_redirect__uri
status_code: status_code
is_custom: is_custom
status: status
enabled: enabled
language: language
created: created
operations: operations
Expand Down Expand Up @@ -786,7 +786,7 @@ display:
separator: ''
empty_column: false
responsive: ''
status:
enabled:
sortable: true
default_sort_order: asc
align: ''
Expand All @@ -802,7 +802,7 @@ display:
responsive: ''
created:
sortable: true
default_sort_order: asc
default_sort_order: desc
align: ''
separator: ''
empty_column: false
Expand Down
30 changes: 22 additions & 8 deletions docker/elastic-proxy/elastic.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,38 @@ server {
server_name _;
client_max_body_size 50m;

location /ping {
add_header Content-Type application/json;
return 200 '{"status":"success","result":"Proxy alive"}';
location /health {
access_log off;

proxy_pass ${ELASTICSEARCH_URL}/_cluster/health;
proxy_ssl_verify off;
proxy_redirect off;
proxy_set_header Authorization $elastic_authorization;
proxy_pass_header Authorization;

proxy_connect_timeout 5s;
proxy_send_timeout 5s;
proxy_read_timeout 5s;
}

location ~ ^/([a-z][a-z_,-]*)/(_search|_msearch)$ {
limit_except GET POST {
deny all;
limit_except GET POST OPTIONS {
deny all;
}

if ($request_method = 'OPTIONS') {
return 204;
}

proxy_pass ${ELASTICSEARCH_URL};
proxy_ssl_verify off;
proxy_redirect off;
proxy_set_header Authorization $elastic_authorization;
proxy_pass_header Authorization;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_pass_header Access-Control-Allow-Origin;
proxy_pass_header Access-Control-Allow-Methods;
proxy_hide_header Access-Control-Allow-Headers;
add_header 'Access-Control-Allow-Origin' '*' always;
add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range,Authorization' always;
}
}
7 changes: 3 additions & 4 deletions docker/openshift/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@ RUN composer install --no-progress --profile --prefer-dist --no-interaction --no

# Copy custom entrypoints.
# @see https://github.com/City-of-Helsinki/drupal-docker-images/tree/main/openshift/drupal
RUN mkdir -p /crons /entrypoints /hooks/deploy /hooks/db-replace
RUN mkdir -p /crons /entrypoints /hooks
COPY docker/openshift/entrypoints/ /entrypoints
COPY docker/openshift/crons/ /crons
COPY docker/openshift/deploy /hooks/deploy
COPY docker/openshift/post-db-replace /hooks/db-replace
RUN chmod +x /entrypoints/* /hooks/deploy/* /crons/* /hooks/db-replace/*
COPY docker/openshift/hooks/ /hooks
RUN chmod -R +x /entrypoints/* /hooks/* /crons/*

COPY docker/openshift/init.sh /
4 changes: 2 additions & 2 deletions tools/make/drupal.mk
Original file line number Diff line number Diff line change
Expand Up @@ -108,11 +108,11 @@ PHONY += drush-import-dump
drush-import-dump: dump.sql
$(call drush,sql-drop --quiet -y)
$(call step,Import local SQL dump...)
$(call drush,sql-query --file=/app/dump.sql && echo 'SQL dump imported')
$(call drush,sql-query --file=/app/dump.sql --extra=--skip-ssl && echo 'SQL dump imported')

PHONY += drush-sanitize-database
drush-sanitize-database:
$(call drush,sql-query \"UPDATE file_managed SET uri = REPLACE(uri, 'azure://', 'public://');\",Fixed Azure URIs)
$(call drush,sql-query --extra=--skip-ssl \"UPDATE file_managed SET uri = REPLACE(uri, 'azure://', 'public://');\",Fixed Azure URIs)

PHONY += drush-create-dump
drush-create-dump: ## Create database dump to dump.sql
Expand Down