Skip to content

Commit f797b8a

Browse files
Update configuration
1 parent 08a9379 commit f797b8a

7 files changed

Lines changed: 332 additions & 229 deletions

File tree

.platform/schema

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
16
1+
17

composer.lock

Lines changed: 321 additions & 216 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

conf/cmi/user.role.anonymous.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ weight: 0
1717
is_admin: false
1818
permissions:
1919
- 'access content'
20+
- 'access debug api'
2021
- 'send javascript errors to sentry'
2122
- 'view helfi_announcements external entity'
2223
- 'view helfi_news external entity'

docker/openshift/Dockerfile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,3 @@ COPY docker/openshift/deploy /deploy
1414
RUN chmod +x /entrypoints/* /deploy/* /crons/*
1515

1616
COPY docker/openshift/init.sh /
17-
18-
# Copy nginx overrides.
19-
COPY docker/openshift/custom.locations /etc/nginx/conf.d/custom.locations

docker/openshift/custom.locations

Lines changed: 0 additions & 8 deletions
This file was deleted.

docker/openshift/preflight/preflight.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,14 @@ function environment_variable_isset(array $items) : bool {
6767
'all.preflight.php',
6868
];
6969

70+
$private_files_folder = getenv('DRUPAL_FILES_PRIVATE');
71+
72+
// Make sure private files folder is outside webroot unless explicitly
73+
// configured so.
74+
if (!$private_files_folder && is_dir('/var/www/html/public/sites/default/files/private')) {
75+
preflight_failed('sites/default/files/private folder found.');
76+
}
77+
7078
// Allow additional custom checks to be added.
7179
// Create a 'all.preflight.php' file for checks that need to be run
7280
// on all environments and '{env}.preflight.php' for environment-specific

public/sites/default/settings.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ function drupal_get_env(string|array $variables) : mixed {
110110

111111
$settings['config_sync_directory'] = '../conf/cmi';
112112
$settings['file_public_path'] = getenv('DRUPAL_FILES_PUBLIC') ?: 'sites/default/files';
113-
$settings['file_private_path'] = getenv('DRUPAL_FILES_PRIVATE');
113+
$settings['file_private_path'] = getenv('DRUPAL_FILES_PRIVATE') ?: '/private_files';
114114
$settings['file_temp_path'] = getenv('DRUPAL_TMP_PATH') ?: '/tmp';
115115

116116
if ($reverse_proxy_address = getenv('DRUPAL_REVERSE_PROXY_ADDRESS')) {

0 commit comments

Comments
 (0)