Turn off Caddy's admin interface and expose metrics on the same port.

This commit is contained in:
Catherine
2025-09-22 16:26:55 +00:00
parent e78f70626e
commit 80e3d7ff56
2 changed files with 20 additions and 12 deletions

View File

@@ -9,6 +9,16 @@
}
{
storage s3 {
host "{env.PAGES_STORAGE_S3_ENDPOINT}"
access_id "{env.PAGES_STORAGE_S3_ACCESS_KEY_ID}"
secret_key "{env.PAGES_STORAGE_S3_SECRET_ACCESS_KEY}"
bucket "{env.PAGES_STORAGE_S3_BUCKET}"
prefix "ssl"
}
admin off
persist_config off
log {
@@ -20,17 +30,7 @@
}
}
metrics {
per_host
}
storage s3 {
host "{env.PAGES_STORAGE_S3_ENDPOINT}"
access_id "{env.PAGES_STORAGE_S3_ACCESS_KEY_ID}"
secret_key "{env.PAGES_STORAGE_S3_SECRET_ACCESS_KEY}"
bucket "{env.PAGES_STORAGE_S3_BUCKET}"
prefix "ssl"
}
metrics
email {env.ACME_EMAIL}
@@ -61,6 +61,11 @@
name health
protocols h1
}
servers :2019 {
name metrics
protocols h1
}
}
(backend) {
@@ -98,3 +103,7 @@ https:// {
http://localhost:2002 {
reverse_proxy http://localhost:3002
}
http://:2019 {
metrics
}

View File

@@ -18,7 +18,6 @@ cpus = 2
memory = 512
[env]
CADDY_ADMIN = ":2019"
UDP_BIND_TO = "fly-global-services"
ALLOW_PROXY = "172.16.0.0/16"
AUTOMEMLIMIT = "0.25"