Rename composer hostnames
Previously, all containers had hostnames corresponding to their domains. This made it impossible to use curl and friends from within the containers. This commit renames the hostnames of the containers to append a '.wisski' suffix.
This commit is contained in:
parent
b461893834
commit
e856afdc93
2 changed files with 2 additions and 2 deletions
|
|
@ -4,7 +4,7 @@ services:
|
||||||
barrel:
|
barrel:
|
||||||
build: .
|
build: .
|
||||||
restart: always
|
restart: always
|
||||||
hostname: ${VIRTUAL_HOST}
|
hostname: ${VIRTUAL_HOST}.wisski
|
||||||
environment:
|
environment:
|
||||||
# port and hostname for this image to use
|
# port and hostname for this image to use
|
||||||
VIRTUAL_HOST: ${VIRTUAL_HOST}
|
VIRTUAL_HOST: ${VIRTUAL_HOST}
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
# This utility script can be used to configure the trusted host settings inside of settings.php.
|
# This utility script can be used to configure the trusted host settings inside of settings.php.
|
||||||
# It doesn't take care of corner cases and should only be used when needed.
|
# It doesn't take care of corner cases and should only be used when needed.
|
||||||
|
|
||||||
INSTANCE_DOMAIN="$(hostname -f)"
|
INSTANCE_DOMAIN="${VIRTUAL_HOST}"
|
||||||
chmod u+w web/sites/default/settings.php
|
chmod u+w web/sites/default/settings.php
|
||||||
echo "" >> web/sites/default/settings.php
|
echo "" >> web/sites/default/settings.php
|
||||||
echo "\$settings['trusted_host_patterns'] = ['${INSTANCE_DOMAIN//\./\\\.}'];" >> web/sites/default/settings.php
|
echo "\$settings['trusted_host_patterns'] = ['${INSTANCE_DOMAIN//\./\\\.}'];" >> web/sites/default/settings.php
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue