From c224004ccf3de92c8318d059b96afbdae1c51f78 Mon Sep 17 00:00:00 2001 From: wizzdom Date: Sun, 18 Feb 2024 22:47:24 +0000 Subject: [PATCH] add privatebin (#24) --- jobs/services/privatebin.hcl | 215 +++++++++++++++++++++++++++++++++++ 1 file changed, 215 insertions(+) create mode 100644 jobs/services/privatebin.hcl diff --git a/jobs/services/privatebin.hcl b/jobs/services/privatebin.hcl new file mode 100644 index 0000000..633803c --- /dev/null +++ b/jobs/services/privatebin.hcl @@ -0,0 +1,215 @@ +job "privatebin" { + datacenters = ["aperture"] + + type = "service" + + group "privatebin" { + count = 1 + + network { + port "http" { + to = 8080 + } + } + + service { + name = "privatebin" + port = "http" + + check { + type = "http" + path = "/" + interval = "10s" + timeout = "2s" + } + + tags = [ + "traefik.enable=true", + "traefik.http.routers.privatebin.rule=Host(`paste.rb.dcu.ie`)", + "traefik.http.routers.privatebin.entrypoints=web,websecure", + "traefik.http.routers.privatebin.tls.certresolver=lets-encrypt", + ] + } + + task "privatebin" { + driver = "docker" + + config { + image = "privatebin/nginx-fpm-alpine:stable" + ports = ["http"] + + volumes = [ + "local/conf.php:/srv/data/conf.php", + ] + } + template { + destination = "local/.env" + env = true + change_mode = "restart" + data = <