linuxserver / docker-minisatip

GNU General Public License v3.0
12 stars 6 forks source link

Do not overwrite WebUI http port in network host mode #26

Closed Asuanin closed 1 year ago

Asuanin commented 2 years ago

I run this container with --net=host because bridge does not support multicast on port 1900. But net host ignore my '-p 8086:8875' and '-e RUN_OPTS="-x 8086"' does not work. (yes this is the sixth service with WebUI on my server)


Expected Behavior

WebUI is running on my port

Current Behavior

WebUI is running on hardcoded port '-e RUN_OPTS="-x 8086"' does not work in host network mode

Steps to Reproduce

'-e RUN_OPTS="-x 8086"'

Environment

OS: Debian Buster CPU architecture: x86_64 How docker service was installed: IMAGE=lscr.io/linuxserver/minisatip

Command used to create docker container (run/create/compose/screenshot)

docker run -d \ --name=$CONTAINER \ --net=host \ -v /etc/localtime:/etc/localtime:ro \ -v /home/$USERNAME/.docker-data/$CONTAINER:/config \ --restart unless-stopped \ -e PUID=$USERID \ -e PGID=$GROUPID \ -e TZ=Europe/Prague \ -e RUN_OPTS="-D 1 -y 5545 -x 8086" \ --device /dev/dvb/adapter0:/dev/dvb/adapter0 \ $IMAGE

My solution:

/etc/services.d/satip/run `#!/usr/bin/with-contenv bash

cd /app/satip || exit

ATTRS=${RUN_OPTS} DEFAULT_HTTP_PORT=8875

if test -n "${ATTRS##-x}"; then PORT=" -x ${DEFAULT_HTTP_PORT}" ATTRS="$ATTRS$PORT" fi

exec \ ./minisatip ${ATTRS} -f `

github-actions[bot] commented 2 years ago

Thanks for opening your first issue here! Be sure to follow the bug or feature issue templates!

github-actions[bot] commented 2 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.