mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-13 11:01:28 +02:00
Update 99-run.sh
This commit is contained in:
@@ -146,17 +146,11 @@ fi
|
|||||||
# Execute main script
|
# Execute main script
|
||||||
# shellcheck ignore=SC1091
|
# shellcheck ignore=SC1091
|
||||||
source /etc/apache2/envvars
|
source /etc/apache2/envvars
|
||||||
echo "python3 /docker-entrypoint.py"
|
echo "Adapting start script"
|
||||||
cd /var2/www/webtrees || exit 1
|
cd /var2/www/webtrees || exit 1
|
||||||
if [ ! -f "${DATA_LOCATION}/config.ini.php" ]; then
|
sed -i "s|%%data_location%%|${DATA_LOCATION}|g" /etc/scripts/launcher.sh
|
||||||
bashio::log.info "First boot : open the UI at $BASE_URL to access the start-up wizard"
|
sed -i "s|%%base_url%%|${BASE_URL}|g" /etc/scripts/launcher.sh
|
||||||
if bashio::services.available 'mysql'; then
|
sed -i "/Starting Apache/a\ subprocess.run('/etc/scripts/launcher.sh', shell=True, check=True)" /docker-entrypoint.py
|
||||||
bashio::log.info "MariaDB is available, if you want to use it please fill the values seen above in the log"
|
|
||||||
else
|
bashio::log.info "Starting webtrees launcher"
|
||||||
bashio::log.info "As you don't have the MariaDB addon running, you should likely select sqlite as database"
|
python3 /docker-entrypoint.py
|
||||||
fi
|
|
||||||
python3 /docker-entrypoint.py
|
|
||||||
else
|
|
||||||
bashio::log.info "Webtrees started. You can access your webui at : $BASE_URL"
|
|
||||||
python3 /docker-entrypoint.py
|
|
||||||
fi
|
|
||||||
|
|||||||
Reference in New Issue
Block a user