add beszel

This commit is contained in:
aykhans committed 2026-10-24 17:56:22 +00:00
1 parent ce080f8908
commit a982fd7e83
7 files changed
+102

No files matched your search

+14
View File
@@ -0,0 +1,14 @@
############# hub #############
# Public URL of the hub; must match BESZEL_DOMAIN in caddy/.env.
APP_URL=https://sub.example.com
############# agent #############
# Both are shown by the hub under "Add System" once it is running. KEY is the
# hub's public key, TOKEN authenticates this host's agent. Fill them in, then
# start the agent.
#
# The agent's remaining settings are not secrets and live in
# docker-compose.yaml instead: LISTEN points at the socket it shares with the
# hub, and no HUB_URL is needed because the hub connects to that socket.
KEY=
TOKEN=
+2
View File
@@ -0,0 +1,2 @@
/data/*
!.gitkeep
View File
Whitespace-only changes.
+50
View File
@@ -0,0 +1,50 @@
networks:
caddy:
name: caddy
driver: bridge
external: true
volumes:
socket:
name: beszel_socket
services:
beszel:
image: henrygd/beszel:0.21
container_name: beszel
restart: unless-stopped
volumes:
- ./data/hub:/beszel_data
- socket:/beszel_socket
networks:
- caddy
env_file:
- ./.env
labels:
com.centurylinklabs.watchtower.enable: true
logging:
driver: "json-file"
options:
max-size: "100m"
max-file: "3"
beszel-agent:
image: henrygd/beszel-agent:0.21
container_name: beszel_agent
restart: unless-stopped
network_mode: host
volumes:
- ./data/agent:/var/lib/beszel-agent
- socket:/beszel_socket
- /var/run/docker.sock:/var/run/docker.sock:ro
env_file:
- ./.env
environment:
LISTEN: /beszel_socket/beszel.sock
labels:
com.centurylinklabs.watchtower.enable: true
logging:
driver: "json-file"
options:
max-size: "100m"
max-file: "3"
+3
View File
@@ -53,3 +53,6 @@ MATRIX_DOMAIN=
############# CrowdSec #############
# Same value as CROWDSEC_BOUNCER_KEY_CADDY in crowdsec/.env
CROWDSEC_API_KEY=
############# Beszel #############
BESZEL_DOMAIN=
+14
View File
@@ -282,3 +282,17 @@
}
import Caddyfile.private
############## beszel ##############
{$BESZEL_DOMAIN} {
import access-log
request_body {
max_size 64MB
}
route {
import security
reverse_proxy http://beszel:8090 {
header_up Host {http.request.host}
}
}
}
+19
View File
@@ -63,6 +63,7 @@ generate_env_files() {
cp --update=none ./ghost/.env.example ./ghost/.env
cp --update=none ./immich/.env.example ./immich/.env
cp --update=none ./uptime_kuma/.env.example ./uptime_kuma/.env
cp --update=none ./beszel/.env.example ./beszel/.env
cp --update=none ./croc/.env.example ./croc/.env
cp --update=none ./stalwart/.env.example ./stalwart/.env
cp --update=none ./crowdsec/.env.example ./crowdsec/.env
@@ -208,6 +209,15 @@ start_services() {
exit 1
fi
echo "Starting beszel..."
$DOCKER_COMPOSE_COMMAND -f ./beszel/docker-compose.yaml up --pull always -d
if [ $? -eq 0 ]; then
print_success "Beszel started successfully."
else
print_error "failed to start Beszel!"
exit 1
fi
echo "Starting croc..."
$DOCKER_COMPOSE_COMMAND -f ./croc/docker-compose.yaml up --pull always -d
if [ $? -eq 0 ]; then
@@ -395,6 +405,15 @@ stop_services() {
exit 1
fi
echo "Stopping beszel..."
$DOCKER_COMPOSE_COMMAND -f ./beszel/docker-compose.yaml down
if [ $? -eq 0 ]; then
print_success "Beszel stopped successfully."
else
print_error "failed to stop Beszel!"
exit 1
fi
echo "Stopping croc..."
$DOCKER_COMPOSE_COMMAND -f ./croc/docker-compose.yaml down
if [ $? -eq 0 ]; then