mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-08 00:25:55 +02:00
Ingress addition
This commit is contained in:
16
binance-trading-bot/rootfs/etc/cont-init.d/32-ingress.sh
Normal file
16
binance-trading-bot/rootfs/etc/cont-init.d/32-ingress.sh
Normal file
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/bashio
|
||||
# shellcheck shell=bash
|
||||
|
||||
#################
|
||||
# NGINX SETTING #
|
||||
#################
|
||||
declare ingress_interface
|
||||
declare ingress_port
|
||||
|
||||
ingress_port="$(bashio::addon.ingress_port)"
|
||||
ingress_interface="$(bashio::addon.ip_address)"
|
||||
ingress_entry=$(bashio::addon.ingress_entry)
|
||||
sed -i "s/%%port%%/${ingress_port}/g" /etc/nginx/servers/ingress.conf
|
||||
sed -i "s/%%interface%%/${ingress_interface}/g" /etc/nginx/servers/ingress.conf
|
||||
sed -i "s|%%ingress_entry%%|${ingress_entry}|g" /etc/nginx/servers/ingress.conf
|
||||
|
||||
@@ -25,5 +25,9 @@ npm start docker-entrypoint.sh & bashio::log.info "Starting binance bot"
|
||||
#########################
|
||||
# Starting Trading View #
|
||||
#########################
|
||||
bashio::log.info "Starting trading view"
|
||||
python main.py
|
||||
python main.py & bashio::log.info "Starting trading view"
|
||||
|
||||
##################
|
||||
# Starting nginx #
|
||||
##################
|
||||
nginx
|
||||
|
||||
Reference in New Issue
Block a user