19 lines
508 B
Bash
19 lines
508 B
Bash
#!/bin/sh
|
|
set -e
|
|
|
|
: "${APACHE_DOCUMENT_ROOT:=/var/www/html/home/web}"
|
|
|
|
placeholder="__FARM3_APACHE_DOCUMENT_ROOT__"
|
|
|
|
sed -ri -e "s~/var/www/html(/home/web|/backend/web)*~${placeholder}~g" \
|
|
/etc/apache2/sites-available/*.conf \
|
|
/etc/apache2/apache2.conf \
|
|
/etc/apache2/conf-available/*.conf
|
|
|
|
sed -ri -e "s|${placeholder}|${APACHE_DOCUMENT_ROOT}|g" \
|
|
/etc/apache2/sites-available/*.conf \
|
|
/etc/apache2/apache2.conf \
|
|
/etc/apache2/conf-available/*.conf
|
|
|
|
exec docker-php-entrypoint "$@"
|