addon-vscode/vscode/rootfs/etc/services.d/code/finish
Franck Nijhof ff3af32124
⬆️ Upgrades add-on base image to 6.1.0 (#477)
* ⬆️ Upgrades add-on base image to 6.1.0

* Fix halt in finish script
2022-07-20 10:24:43 +02:00

11 lines
512 B
Text
Executable file

#!/command/with-contenv bashio
# ==============================================================================
# Home Assistant Community Add-on: Studio Code Server
# Take down the S6 supervision tree when the code server fails
# ==============================================================================
if [[ "${1}" -ne 0 ]] && [[ "${1}" -ne 256 ]]; then
bashio::log.warning "code-server crashed, halting add-on"
exec /run/s6/basedir/bin/halt
fi
bashio::log.info "code-server stopped, restarting..."