Compare commits

..

2 Commits

Author SHA1 Message Date
Xe Iaso 4d799c7858 test: add nginx config smoke test based on the config in the docs
Signed-off-by: Xe Iaso <me@xeiaso.net>
2025-12-28 18:12:49 -05:00
Xe Iaso 07a571d6cd docs: split nginx configuration files to their own directory
Signed-off-by: Xe Iaso <me@xeiaso.net>
2025-12-28 15:14:15 -05:00
3 changed files with 8 additions and 10 deletions
-7
View File
@@ -17,7 +17,6 @@ import (
"net" "net"
"net/http" "net/http"
"net/http/httputil" "net/http/httputil"
"net/http/pprof"
"net/url" "net/url"
"os" "os"
"os/signal" "os/signal"
@@ -543,12 +542,6 @@ func metricsServer(ctx context.Context, lg slog.Logger, done func()) {
} }
}) })
mux.HandleFunc("GET /debug/pprof/", pprof.Index)
mux.HandleFunc("GET /debug/pprof/cmdline", pprof.Cmdline)
mux.HandleFunc("GET /debug/pprof/profile", pprof.Profile)
mux.HandleFunc("GET /debug/pprof/symbol", pprof.Symbol)
mux.HandleFunc("GET /debug/pprof/trace", pprof.Trace)
srv := http.Server{Handler: mux, ErrorLog: internal.GetFilteredHTTPLogger()} srv := http.Server{Handler: mux, ErrorLog: internal.GetFilteredHTTPLogger()}
listener, metricsUrl := setupListener(*metricsBindNetwork, *metricsBind) listener, metricsUrl := setupListener(*metricsBindNetwork, *metricsBind)
lg.Debug("listening for metrics", "url", metricsUrl) lg.Debug("listening for metrics", "url", metricsUrl)
+1 -2
View File
@@ -11,8 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased] ## [Unreleased]
- Add Polish locale ([#1292](https://github.com/TecharoHQ/anubis/pull/1309)). - Add Polish locale ([#1292](https://github.com/TecharoHQ/anubis/pull/1309))
- Expose [pprof endpoints](https://pkg.go.dev/net/http/pprof) on the metrics listener to enable profiling Anubis in production.
<!-- This changes the project to: --> <!-- This changes the project to: -->
+7 -1
View File
@@ -7,12 +7,18 @@ source ../lib/lib.sh
set -euo pipefail set -euo pipefail
build_anubis_ko
mint_cert mimi.techaro.lol mint_cert mimi.techaro.lol
docker run --rm \ docker run --rm -it \
-v ./conf/nginx:/etc/nginx:ro \ -v ./conf/nginx:/etc/nginx:ro \
-v ../pki:/techaro/pki:ro \ -v ../pki:/techaro/pki:ro \
nginx \ nginx \
nginx -t nginx -t
docker compose up -d
docker compose down -t 1 || :
docker compose rm -f || :
exit 0 exit 0