Added Caddyfile configuration + Searxng job

This commit is contained in:
Zuma 2025-11-08 16:52:35 +01:00
parent c4246661ef
commit 255a0e0e61
4 changed files with 52 additions and 0 deletions

11
apps/caddy/Caddyfile Normal file
View file

@ -0,0 +1,11 @@
{
email zuma@deuxfleurs.fr
}
chokbar.bzh {
respond "Kenavo !"
}
search.chokbar.bzh {
reverse_proxy searxng.service.consul:8080
}

View file

@ -16,6 +16,9 @@ job "caddy" {
image = "caddy"
network_mode = "host"
ports = [ "http_port", "https_port" ]
volumes = [
"secrets/Caddyfile:/etc/caddy/Caddyfile"
]
}
resources {
@ -23,6 +26,12 @@ job "caddy" {
memory = 400
}
template {
data = file("./Caddyfile")
destination = "secrets/Caddyfile"
perms = 400
}
service {
name = "caddy-http"
port = "http_port"

30
apps/searxng/searxng.hcl Normal file
View file

@ -0,0 +1,30 @@
job "searxng" {
datacenters = [ "gribse-house", "zuma-house", "mayel-house" ]
type = "service"
priority = 90
group "searxng" {
network {
port "http_port" { static = 8080 }
}
task "server" {
driver = "docker"
config {
image = "searxng/searxng:latest"
ports = [ "http_port" ]
}
resources {
cpu = 500
memory = 200
}
service {
name = "searxng"
port = "http_port"
}
}
}
}

View file

@ -279,6 +279,8 @@ with pkgs.lib;
enable = true;
allowedTCPPorts = [
22 # SSH
80 # HTTP
443 # HTTPS
];
allowedUDPPorts = [
19720 # Wireguard