diff --git a/README.md b/README.md index 2441047..839ed5a 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,7 @@ Flarum is the next-generation forum software that makes online discussion fun. I | -------- | ----------- | ---- | ------------- | | **GID** | Flarum user id | *optional* | 991 | **UID** | Flarum group id | *optional* | 991 +| **DEBUG** | Flarum debug mode | *optional* | false | **FORUM_URL** | Forum URL | **required** | none | **DB_HOST** | MariaDB instance ip/hostname | *optional* | mariadb | **DB_USER** | MariaDB database username | *optional* | flarum diff --git a/startup b/startup index 22fd3ca..5823384 100644 --- a/startup +++ b/startup @@ -4,11 +4,13 @@ export DB_HOST export DB_USER export DB_NAME +export DEBUG # Default values DB_HOST=${DB_HOST:-mariadb} DB_USER=${DB_USER:-flarum} DB_NAME=${DB_NAME:-flarum} +DEBUG=${DEBUG:-false} # Required env variables if [ -z "$DB_PASS" ]; then @@ -105,6 +107,11 @@ else fi +# Set flarum debug mode +if [ -f "config.php" ]; then + sed -i "s|\('debug' =>\) .*|\1 ${DEBUG},|" config.php +fi + # Removing installation files rm -f config.sql config.yml