mirror of
https://github.com/gurucomputing/headscale-ui.git
synced 2026-07-17 16:39:45 +00:00
Merge pull request #16 from gurucomputing/chore_add-port-environment-variable
added custom port option
This commit is contained in:
commit
f8b6afc26d
2 changed files with 8 additions and 0 deletions
|
|
@ -30,6 +30,8 @@ FROM alpine:latest
|
|||
ENV PROJECT_NAME="headscale-ui"
|
||||
# URL for the github/git location
|
||||
ENV PROJECT_URL="https://github.com/gurucomputing/headscale-ui"
|
||||
# Port that caddy will run on
|
||||
ENV PORT="443"
|
||||
|
||||
# Production Web Server port. Runs a self signed SSL certificate
|
||||
EXPOSE 443
|
||||
|
|
|
|||
|
|
@ -12,5 +12,11 @@ then
|
|||
cp /staging/Caddyfile /data/Caddyfile
|
||||
fi
|
||||
|
||||
# replace port in Caddyfile if set
|
||||
if [ "$PORT" != "443" ]
|
||||
then
|
||||
sed -i "s/:443/$PORT/g" /data/Caddyfile
|
||||
fi
|
||||
|
||||
echo "Starting Caddy"
|
||||
/usr/sbin/caddy run --adapter caddyfile --config /data/Caddyfile
|
||||
Loading…
Add table
Add a link
Reference in a new issue