diff --git a/build b/build new file mode 100755 index 0000000..9a6ac6f --- /dev/null +++ b/build @@ -0,0 +1,4 @@ +#!/usr/bin/bash + +# Build the Docker image +docker build -t skoszewski/omada-dyndns-miab-proxy . diff --git a/entrypoint.sh b/entrypoint.sh new file mode 100644 index 0000000..d2003fb --- /dev/null +++ b/entrypoint.sh @@ -0,0 +1,14 @@ +#!/bin/sh + +set -e + +LISTEN_ADDRESS="${LISTEN_ADDRESS:-0.0.0.0}" +LISTEN_PORT="${LISTEN_PORT:-8080}" + +cd /app + +if [ -z "$CERT_FILE" ] || [ -z "$KEY_FILE" ]; then + exec gunicorn --bind ${LISTEN_ADDRESS}:${LISTEN_PORT} app:app +else + exec gunicorn --bind ${LISTEN_ADDRESS}:${LISTEN_PORT} --certfile=${CERT_FILE} --keyfile=${KEY_FILE} app:app +fi