mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-01-10 09:51:02 +01:00
17 lines
652 B
Plaintext
17 lines
652 B
Plaintext
#!/usr/bin/env bashio
|
|
# shellcheck shell=bash
|
|
set -e
|
|
|
|
PATHTOFILES="$(bashio::config "CONFIG_LOCATION")"
|
|
PATHTOFILES="$(dirname "${PATHTOFILES}")"
|
|
|
|
(
|
|
bashio::log.info "Running update according to defined schedule. Files located in $PATHTOFILES will be imported"
|
|
if bashio::config.true 'silent'; then
|
|
bashio::log.warning "Silent mode activated. Only errors will be shown. Please disable in addon options if you need to debug"
|
|
/usr/local/bin/php /var/www/html/artisan importer:auto-import "$PATHTOFILES/import_files" >/dev/null
|
|
else
|
|
/usr/local/bin/php /var/www/html/artisan importer:auto-import "$PATHTOFILES/import_files"
|
|
fi
|
|
) &>/proc/1/fd/1
|