2023-08-24 01:31:08 +02:00
|
|
|
#!/bin/sh
|
2023-08-25 03:50:05 +02:00
|
|
|
set -e
|
2024-03-22 08:34:50 +01:00
|
|
|
|
|
|
|
# remove quotes from variable if present
|
|
|
|
FOURGET_PROTO="${FOURGET_PROTO%\"}"
|
|
|
|
FOURGET_PROTO="${FOURGET_PROTO#\"}"
|
|
|
|
|
2024-04-19 22:47:02 +02:00
|
|
|
# make lowercase
|
|
|
|
FOURGET_PROTO=`echo $FOURGET_PROTO | awk '{print tolower($0)}'`
|
|
|
|
|
|
|
|
|
2024-04-25 01:11:49 +02:00
|
|
|
if [ "$FOURGET_PROTO" = "https" ]; then
|
2024-02-09 10:59:25 +01:00
|
|
|
echo "Using https configuration"
|
|
|
|
cp /etc/apache2/https.conf /etc/apache2/httpd.conf
|
2024-03-22 08:34:50 +01:00
|
|
|
else
|
|
|
|
echo "Using http configuration"
|
|
|
|
cp /etc/apache2/http.conf /etc/apache2/httpd.conf
|
2023-09-22 23:20:39 +02:00
|
|
|
fi
|
|
|
|
|
2024-03-22 08:34:50 +01:00
|
|
|
php ./docker/gen_config.php
|
2024-01-09 08:14:27 +01:00
|
|
|
|
|
|
|
|
2023-09-22 23:20:39 +02:00
|
|
|
echo "4get is running"
|
2023-08-25 03:50:05 +02:00
|
|
|
exec httpd -DFOREGROUND
|
2023-09-22 23:20:39 +02:00
|
|
|
|