From e847091076e7cbe28628247e336e397a3960f735 Mon Sep 17 00:00:00 2001 From: Kirby0025 Date: Mon, 2 Jun 2025 11:39:12 +0200 Subject: [PATCH 1/3] feat(docs): adding haproxy configuration example --- documentation/docs/install/getting_started.md | 1 + documentation/docs/install/haproxy.md | 23 +++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 documentation/docs/install/haproxy.md diff --git a/documentation/docs/install/getting_started.md b/documentation/docs/install/getting_started.md index a74d6a6..37cc163 100644 --- a/documentation/docs/install/getting_started.md +++ b/documentation/docs/install/getting_started.md @@ -13,3 +13,4 @@ AdventureLog can be installed in a variety of ways. The following are the most c - [Nginx Proxy Manager](nginx_proxy_manager.md) 🛡 - [Traefik](traefik.md) 🚀 - [Caddy](caddy.md) 🔒 +- [HAProxy](haproxy.md) diff --git a/documentation/docs/install/haproxy.md b/documentation/docs/install/haproxy.md new file mode 100644 index 0000000..c0b104d --- /dev/null +++ b/documentation/docs/install/haproxy.md @@ -0,0 +1,23 @@ +# Installation with Haproxy + +HAProxy is a free and open source software that provides a high availability load balancer and Proxy for TCP and HTTP-based applications. + +You need to make the frontend and the backend available in order to have your AdventureLog working properly. +To do this, you will need to add 2 ACLs and 2 corresponding HAProxy backends in your haproxy configuration : +- One for your regular Adventurelog domain that will direct the requests to the frontend. +- One for the URLs that need to access the backend. + +Example : + +``` +acl is_adventurelog hdr_sub(Host) -i adventurelog +acl is_adventurelog_backend path_beg /media/ or /admin/ + +use_backend adventurelog_media if is_adventurelog is_adventurelog_backend +use_backend adventurelog if is_adventurelog + +backend alog + server adventurelog 192.168.1.100:3000 check +backend adventurelog_backend + server adventurelog_media 192.168.1.100:8000 check +``` From ce3fa9d5e311affdba7af0ed73e4f088557cfbf4 Mon Sep 17 00:00:00 2001 From: Sean Morley Date: Mon, 23 Jun 2025 23:17:06 -0400 Subject: [PATCH 2/3] fix(docs): enhance HAProxy description in installation guide --- documentation/.vitepress/config.mts | 1 + documentation/docs/install/getting_started.md | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/documentation/.vitepress/config.mts b/documentation/.vitepress/config.mts index 212eedb..a4a60f4 100644 --- a/documentation/.vitepress/config.mts +++ b/documentation/.vitepress/config.mts @@ -149,6 +149,7 @@ export default defineConfig({ }, { text: "Traefik", link: "/docs/install/traefik" }, { text: "Caddy", link: "/docs/install/caddy" }, + { text: "HAProxy", link: "/docs/install/haproxy" }, ], }, ], diff --git a/documentation/docs/install/getting_started.md b/documentation/docs/install/getting_started.md index c76ebcc..05e427e 100644 --- a/documentation/docs/install/getting_started.md +++ b/documentation/docs/install/getting_started.md @@ -24,4 +24,4 @@ Perfect for Docker beginners. - [Nginx Proxy Manager](nginx_proxy_manager.md) — Easy reverse proxy config - [Traefik](traefik.md) — Dynamic reverse proxy with automation - [Caddy](caddy.md) — Automatic HTTPS with a clean config -- [HAProxy](haproxy.md) +- [HAProxy](haproxy.md) — High-performance reverse proxy with advanced control From fc358b9efc6bf9d260b06c23990efd5b41928df4 Mon Sep 17 00:00:00 2001 From: Kirby0025 Date: Mon, 7 Jul 2025 16:16:13 +0200 Subject: [PATCH 3/3] enhance haproxy example --- documentation/docs/install/haproxy.md | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/documentation/docs/install/haproxy.md b/documentation/docs/install/haproxy.md index c0b104d..1d33c05 100644 --- a/documentation/docs/install/haproxy.md +++ b/documentation/docs/install/haproxy.md @@ -10,13 +10,21 @@ To do this, you will need to add 2 ACLs and 2 corresponding HAProxy backends in Example : ``` -acl is_adventurelog hdr_sub(Host) -i adventurelog -acl is_adventurelog_backend path_beg /media/ or /admin/ +listen http-s + bind :80 -use_backend adventurelog_media if is_adventurelog is_adventurelog_backend -use_backend adventurelog if is_adventurelog + timeout connect 5s + timeout client 60s -backend alog + mode http + + acl is_adventurelog hdr_sub(Host) -i adventurelog + acl is_adventurelog_backend path_beg /media/ or /admin/ + + use_backend adventurelog_media if is_adventurelog is_adventurelog_backend + use_backend adventurelog if is_adventurelog + +backend adventurelog server adventurelog 192.168.1.100:3000 check backend adventurelog_backend server adventurelog_media 192.168.1.100:8000 check