aboutsummaryrefslogtreecommitdiffstats
path: root/Caddyfile
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2022-09-23 07:06:35 +0000
committerAdam Soltys <[email protected]>2022-09-23 07:06:35 +0000
commit6059ca000e68277dfc951bd56b6e46f65e860046 (patch)
tree9a9b358efd6d989155e6413ca9a5d7a9140a0c63 /Caddyfile
parentfa016bdd0eb3939c77f99e27af9a41923c2a7274 (diff)
downloadcoinos-server-6059ca000e68277dfc951bd56b6e46f65e860046.tar.gz
coinos-server-6059ca000e68277dfc951bd56b6e46f65e860046.zip
caddy cloudflare plugin
Diffstat (limited to 'Caddyfile')
-rw-r--r--Caddyfile56
1 files changed, 41 insertions, 15 deletions
diff --git a/Caddyfile b/Caddyfile
index 3dc0100b..16535102 100644
--- a/Caddyfile
+++ b/Caddyfile
@@ -1,19 +1,45 @@
-:80 {
- handle_path /api* {
- reverse_proxy app:3119
- }
+classic.coinos.io {
+ handle_path /api* {
+ reverse_proxy app:3119
+ }
- handle /lnurl* {
- reverse_proxy app:3118
- }
+ handle /lnurl* {
+ reverse_proxy app:3118
+ }
- handle /ws* {
- reverse_proxy app:3119
- }
+ handle /ws* {
+ reverse_proxy app:3119
+ }
- handle {
- root * /coinos
- try_files {path}.html {path} /index.html
- file_server
- }
+ handle {
+ root * /coinos
+ try_files {path}.html {path} /index.html
+ file_server
+ }
+
+ tls {
+ dns cloudflare {env.CLOUDFLARE_AUTH_TOKEN}
+ }
+}
+
+coinos.io {
+ handle_path /api* {
+ reverse_proxy app:3119
+ }
+
+ handle /lnurl* {
+ reverse_proxy app:3118
+ }
+
+ handle /ws* {
+ reverse_proxy app:3119
+ }
+
+ handle {
+ reverse_proxy ui:3000
+ }
+
+ tls {
+ dns cloudflare {env.CLOUDFLARE_AUTH_TOKEN}
+ }
}