mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-05-27 10:54:14 +02:00
Document cron toggle and bump version
This commit is contained in:
@@ -10,6 +10,22 @@ HOME="/config/addons_config/epicgamesfree"
|
||||
CONFIG_JSON="$HOME/config.json"
|
||||
LEGACY_YAML="$HOME/config.yaml"
|
||||
|
||||
if bashio::config.true 'disable_cron'; then
|
||||
bashio::log.info "Disabling cron service as requested by configuration"
|
||||
|
||||
if bashio::command.exists s6-rc && s6-rc -a list | grep -q "^cron$"; then
|
||||
s6-rc -d change cron || true
|
||||
fi
|
||||
|
||||
if [ -d /etc/services.d/cron ]; then
|
||||
rm -rf /etc/services.d/cron
|
||||
fi
|
||||
|
||||
if bashio::command.exists service; then
|
||||
service cron stop >/dev/null 2>&1 || true
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ ! -f "$CONFIG_JSON" ]; then
|
||||
if [ -f "$LEGACY_YAML" ]; then
|
||||
bashio::log.warning "A legacy config.yaml was found. A default config.json will be created. Please migrate your settings to the new file format and restart the add-on"
|
||||
|
||||
Reference in New Issue
Block a user