mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-14 19:41:31 +02:00
Add Home Assistant ingress support for Seerr addon with nginx reverse proxy
Co-authored-by: alexbelgium <44178713+alexbelgium@users.noreply.github.com>
This commit is contained in:
20
seerr/rootfs/etc/cont-init.d/32-nginx_ingress.sh
Normal file
20
seerr/rootfs/etc/cont-init.d/32-nginx_ingress.sh
Normal file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/with-contenv bashio
|
||||
# shellcheck shell=bash
|
||||
set -e
|
||||
|
||||
####################
|
||||
# Seerr Ingress #
|
||||
####################
|
||||
|
||||
bashio::log.info "Configuring Nginx for ingress..."
|
||||
|
||||
ingress_port=$(bashio::addon.ingress_port)
|
||||
ingress_interface=$(bashio::addon.ip_address)
|
||||
ingress_entry=$(bashio::addon.ingress_entry)
|
||||
|
||||
# Update ingress.conf with actual values
|
||||
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
|
||||
|
||||
bashio::log.info "Nginx ingress configured on ${ingress_interface}:${ingress_port}"
|
||||
Reference in New Issue
Block a user