From 316d7b52d825c301f67f18fa0e66af22b2a766dc Mon Sep 17 00:00:00 2001 From: videogame hacker Date: Thu, 16 Nov 2023 04:35:44 +0000 Subject: [PATCH] Add ngx script for nginx config --- .gitmodules | 3 +++ bio-char-lt.ngx.ts | 12 ++++++++++++ 2 files changed, 15 insertions(+) create mode 100644 .gitmodules create mode 100644 bio-char-lt.ngx.ts diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..ba6b731 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "ngx"] + path = ngx + url = git@lavender.software:char/ngx.git diff --git a/bio-char-lt.ngx.ts b/bio-char-lt.ngx.ts new file mode 100644 index 0000000..c4c7b88 --- /dev/null +++ b/bio-char-lt.ngx.ts @@ -0,0 +1,12 @@ +#!/usr/bin/env -S deno run -A + +import ngx from "https://char.lt/ngx/ngx.ts?v=1"; + +ngx("server", [ + [ + "server_name bio.char.lt", + ...ngx.listen(), + ...ngx.letsEncrypt("bio.char.lt"), + ], + ngx("location /", ["root /srv/http/bio.char.lt/public"]), +]).write("/etc/nginx/http.d/bio-char-lt.conf");