scripts/fogcutter/docker/nginx.sh

42 lines
1016 B
Bash
Executable File

#!/bin/bash
set -e
up () {
docker network create pew-net || true
# main nginx container
# for local access hard-code IP in /etc/hosts
docker run \
--detach \
--name nginx \
--restart unless-stopped \
--env PUID=1000 \
--env GUID=1000 \
--env TZ=US/Eastern \
--env URL=seaturtle.pw \
--env VALIDATION=http \
--env EMAIL=paulsw.pw@gmail.com \
--env SUBDOMAINS=airsonic,cave,ff,git,jf,nc,plex \
--volume /bigdata/k8s-config/nginx/nginx.conf:/config/nginx/nginx.conf:ro \
--volume /bigdata/files:/files:ro \
--volume /bigdata/k8s-config/nginx/config:/config:rw \
--volume /bigdata/k8s-config/nginx/ssl.conf:/config/nginx/ssl.conf:ro \
--volume /bigdata/k8s-config/nginx/site-confs:/config/nginx/site-confs:ro \
--publish 127.0.0.1:80:80 \
--publish 443:443 \
--network pew-net \
ghcr.io/linuxserver/swag:1.15.0-ls57
}
down () {
docker stop nginx || true
docker rm nginx || true
}
logs () {
docker logs --follow nginx
}
$@