2022-03-09 09:42:15 -05:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
up () {
|
2022-12-23 19:30:06 -05:00
|
|
|
# Ensure iptables rules exist
|
|
|
|
# https://askubuntu.com/questions/1052919/iptables-reload-restart-on-ubuntu/1072948#1072948
|
|
|
|
docker network create --ipv6 --subnet "fd01::/80" pew-net || true
|
2022-03-09 09:42:15 -05:00
|
|
|
|
|
|
|
# Exposed on port 8080 in pew-net
|
|
|
|
docker run \
|
|
|
|
--detach \
|
|
|
|
--name mapproxy \
|
|
|
|
--volume /bigdata/k8s-config/mapproxy/mapproxy.yaml:/mapproxy/mapproxy.yaml:ro \
|
|
|
|
--volume /bigdata/k8s-config/mapproxy/seed.yaml:/mapproxy/seed.yaml:ro \
|
|
|
|
--volume /bigdata/gis/mapproxy/cache_data:/mapproxy/cache_data:rw \
|
|
|
|
--network pew-net \
|
|
|
|
docker.io/kartoza/mapproxy:latest
|
|
|
|
}
|
|
|
|
|
|
|
|
down () {
|
|
|
|
docker stop mapproxy || true
|
|
|
|
docker rm mapproxy || true
|
|
|
|
}
|
|
|
|
|
|
|
|
logs () {
|
|
|
|
docker logs --follow mapproxy
|
|
|
|
}
|
|
|
|
|
|
|
|
$@
|