mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-11 01:55:59 +02:00
Add set -e
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
DEBUG=$(bashio::config 'TZ')
|
||||
[ "$DEBUG" = "debug" ] && echo "Before declare"
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
##########
|
||||
# INIT #
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
# ==============================================================================
|
||||
|
||||
declare openvpn_config
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
WEBUI_PORT=${WEBUI_PORT:-8080}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
WEBUI_PORT=${WEBUI_PORT:-8080}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
# ==============================================================================
|
||||
|
||||
# Wait for transmission to become available
|
||||
@@ -10,7 +11,7 @@ bashio::log.info "Starting NGinx..."
|
||||
# Check vpn is working
|
||||
if [ -f /currentip ]; then
|
||||
exec nginx & \
|
||||
while true; do
|
||||
while true; do
|
||||
# Get vpn ip
|
||||
if bashio::config.true 'openvpn_alt_mode'; then
|
||||
curl -s ipecho.net/plain > /vpnip
|
||||
@@ -30,7 +31,7 @@ if [ -f /currentip ]; then
|
||||
# Inform by message
|
||||
bashio::log.info "VPN is up and running with ip $(cat /vpnip), based in country : $COUNTRY"
|
||||
|
||||
# Check every 15m
|
||||
# Check every 15m
|
||||
sleep 15m
|
||||
|
||||
true
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
RUNTIME=$(bashio::config 'run_duration')
|
||||
|
||||
|
||||
Reference in New Issue
Block a user