Fix indent
This commit is contained in:
parent
56500a9e8b
commit
318d222f55
34
start.sh
34
start.sh
|
@ -5,28 +5,28 @@ set -eu
|
||||||
mkdir -p /run/php/sessions
|
mkdir -p /run/php/sessions
|
||||||
|
|
||||||
if ! [ -f /app/data/.installed ]; then
|
if ! [ -f /app/data/.installed ]; then
|
||||||
echo "Fresh installation, setting up..."
|
echo "==> Fresh installation, setting up..."
|
||||||
rsync -a /app/code/data-orig/ /app/data/
|
rsync -a /app/code/data-orig/ /app/data/
|
||||||
php cli/do-install.php \
|
php cli/do-install.php \
|
||||||
--environment production --default_user admin \
|
--environment production --default_user admin \
|
||||||
--db-type mysql --db-host "${MYSQL_HOST}" \
|
--db-type mysql --db-host "${MYSQL_HOST}" \
|
||||||
--db-user "${MYSQL_USERNAME}" --db-password "${MYSQL_PASSWORD}" \
|
--db-user "${MYSQL_USERNAME}" --db-password "${MYSQL_PASSWORD}" \
|
||||||
--db-base "${MYSQL_DATABASE}" --db-prefix "" \
|
--db-base "${MYSQL_DATABASE}" --db-prefix "" \
|
||||||
--disable_update
|
--disable_update
|
||||||
php cli/create-user.php --user admin --password changeme --language en
|
php cli/create-user.php --user admin --password changeme --language en
|
||||||
php cli/actualize-user.php --user admin
|
php cli/actualize-user.php --user admin
|
||||||
touch /app/data/.installed
|
touch /app/data/.installed
|
||||||
echo "Done."
|
echo "==> Done."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
echo "Symlinking log file"
|
echo "==> Symlinking log file"
|
||||||
rm -f /app/data/users/_/log_api.txt
|
rm -f /app/data/users/_/log_api.txt
|
||||||
touch /tmp/log_api.txt
|
touch /tmp/log_api.txt
|
||||||
ln -s /tmp/log_api.txt /app/data/users/_/log_api.txt
|
ln -s /tmp/log_api.txt /app/data/users/_/log_api.txt
|
||||||
|
|
||||||
# We have to copy instead of symlinking extensions (see #2)
|
# We have to copy instead of symlinking extensions (see #2)
|
||||||
echo "Copying packaged extensions"
|
echo "==> Copying packaged extensions"
|
||||||
mkdir -p /app/data/extensions
|
mkdir -p /app/data/extensions
|
||||||
for f in $(ls /app/code/extensions-orig); do
|
for f in $(ls /app/code/extensions-orig); do
|
||||||
rm -rf "/app/data/extensions/$f"
|
rm -rf "/app/data/extensions/$f"
|
||||||
|
@ -34,7 +34,7 @@ for f in $(ls /app/code/extensions-orig); do
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
echo "Updating config file"
|
echo "==> Updating config file"
|
||||||
php cli/reconfigure.php --default_user admin --base_url "https://${APP_DOMAIN}" \
|
php cli/reconfigure.php --default_user admin --base_url "https://${APP_DOMAIN}" \
|
||||||
--db-type mysql --db-host "${MYSQL_HOST}" \
|
--db-type mysql --db-host "${MYSQL_HOST}" \
|
||||||
--db-user "${MYSQL_USERNAME}" --db-password "${MYSQL_PASSWORD}" \
|
--db-user "${MYSQL_USERNAME}" --db-password "${MYSQL_PASSWORD}" \
|
||||||
|
@ -42,11 +42,11 @@ php cli/reconfigure.php --default_user admin --base_url "https://${APP_DOMAIN}"
|
||||||
--disable_update
|
--disable_update
|
||||||
|
|
||||||
|
|
||||||
echo "Setting permissions"
|
echo "==> Setting permissions"
|
||||||
chown -R www-data.www-data /run/php /app/data /tmp/log_api.txt
|
chown -R www-data.www-data /run/php /app/data /tmp/log_api.txt
|
||||||
|
|
||||||
|
|
||||||
echo "Starting apache"
|
echo "==> Starting apache"
|
||||||
APACHE_CONFDIR="" source /etc/apache2/envvars
|
APACHE_CONFDIR="" source /etc/apache2/envvars
|
||||||
rm -f "${APACHE_PID_FILE}"
|
rm -f "${APACHE_PID_FILE}"
|
||||||
exec /usr/sbin/apache2 -DFOREGROUND
|
exec /usr/sbin/apache2 -DFOREGROUND
|
||||||
|
|
Loading…
Reference in New Issue