Use CMD again

This commit is contained in:
Felipe Santos 2022-11-14 14:24:23 -03:00
parent 4aa5679830
commit 633d8d214d
5 changed files with 8 additions and 26 deletions

View File

@ -62,7 +62,8 @@ ENV FLASK_ENV=development
ENV S6_SERVICES_READYTIME=50
# https://github.com/hassio-addons/addon-debian-base/pull/126
RUN rm -f /etc/cont-init.d/00-banner.sh /etc/cont-init.d/01-log-level.sh
# https://github.com/hassio-addons/addon-debian-base/pull/127
RUN rm -f /etc/cont-init.d/*
COPY --from=wheels /wheels /wheels
@ -156,3 +157,5 @@ EXPOSE 5000
EXPOSE 1935
EXPOSE 8554
EXPOSE 8555
CMD ["python3", "-u", "-m", "frigate"]

View File

@ -1,12 +0,0 @@
#!/command/with-contenv bashio
# ==============================================================================
# Take down the S6 supervision tree when Frigate fails
# ==============================================================================
# shellcheck shell=bash
if [[ "${1}" -ne 0 ]] && [[ "${1}" -ne 256 ]]; then
bashio::log.warning "Frigate crashed, halting container..."
/run/s6/basedir/bin/halt
fi
bashio::log.info "Frigate stopped, restarting..."

View File

@ -1,9 +0,0 @@
#!/command/with-contenv bashio
# ==============================================================================
# Runs Frigate
# ==============================================================================
# shellcheck shell=bash
bashio::log.info 'Starting Frigate...'
exec python3 -u -m frigate

View File

@ -7,6 +7,6 @@
if [[ "${1}" -ne 0 ]] && [[ "${1}" -ne 256 ]]; then
bashio::log.warning "go2rtc crashed, halting container..."
/run/s6/basedir/bin/halt
fi
else
bashio::log.info "go2rtc stopped, restarting..."
fi

View File

@ -7,6 +7,6 @@
if [[ "${1}" -ne 0 ]] && [[ "${1}" -ne 256 ]]; then
bashio::log.warning "NGINX crashed, halting container..."
/run/s6/basedir/bin/halt
fi
else
bashio::log.info "NGINX stopped, restarting..."
fi