mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-08-02 11:20:32 +02:00
First version
This commit is contained in:
30
epicgamesfree/rootfs/etc/cont-init.d/99-run.sh
Normal file
30
epicgamesfree/rootfs/etc/cont-init.d/99-run.sh
Normal file
@@ -0,0 +1,30 @@
|
||||
#!/usr/bin/env bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
##############
|
||||
# Initialize #
|
||||
##############
|
||||
|
||||
# Copy default config.json
|
||||
HOME="/config/addons_config/epicgamesfree"
|
||||
if [ ! -f "$HOME"/config.json ]; then
|
||||
cp /templates/config.json "$HOME"/config.json
|
||||
chmod 777 "$HOME"/config.json
|
||||
bashio::log.warning "A default config.json file was copied in $HOME. Please customize according to https://github.com/claabs/epicgames-freegames-node#json-configuration before restarting the addon"
|
||||
bashio::exit.nok
|
||||
fi
|
||||
|
||||
# Make symlink
|
||||
|
||||
if [ -f /usr/app/config/config.json ]; then rm /usr/app/config/config.json; fi
|
||||
ln -s "$HOME"/config.json /usr/app/config/config.json
|
||||
|
||||
##############
|
||||
# Launch App #
|
||||
##############
|
||||
|
||||
echo " "
|
||||
bashio::log.info "Starting the app"
|
||||
echo " "
|
||||
|
||||
/./usr/local/bin/docker-entrypoint.sh
|
||||
Reference in New Issue
Block a user