Skip to content

Commit 90db6ca

Browse files
committed
chore(caddy): move per-project configs off the main Caddyfile [skip ci]
Warning: This is breaking change, may need manual testing before deploying.
1 parent d1c8126 commit 90db6ca

File tree

2 files changed

+47
-46
lines changed

2 files changed

+47
-46
lines changed

config/caddy/Caddyfile

Lines changed: 3 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
}
3737
}
3838

39+
# For debugging purposes only
3940
http://localhost:4208 {
4041
import globals
4142

@@ -63,49 +64,5 @@ https:// {
6364
}
6465
}
6566

66-
## RecapTime.dev project domains - START ##
67-
*.lorebooks.wiki, *.beta.lorebooks.wiki, *.lorebooks.eu.org, *.beta.lorebooks.eu.org {
68-
import globals cf_dns01_challenge
69-
70-
@proxyparty host proxyparty.lorebooks.wiki proxyparty.lorebooks.eu.org
71-
@ajhalili2006 host ajhalili2006.lorebooks.wiki ajhalili2006.lorebooks.eu.org andreijiroh.lorebooks.wiki andreijiroh.lorebooks.eu.org
72-
73-
handle @proxyparty {
74-
redir https://gitlab.com/recaptime-dev/infra/proxyparty-caddy
75-
}
76-
77-
handle @ajhalili2006 {
78-
redir https://wiki.andreijiroh.dev{path}
79-
}
80-
81-
handle {
82-
root * ./pages/parking.lorebooks.wiki
83-
encode gzip
84-
try_files {path} /index.html
85-
file_server
86-
}
87-
}
88-
89-
*.stellapent.wiki stellapent.wiki {
90-
import globals cf_dns01_challenge
91-
92-
handle {
93-
root * ./pages/parking.lorebooks.wiki
94-
encode gzip
95-
try_files {path} /index.html
96-
file_server
97-
}
98-
}
99-
100-
*.recaptime.dev, *.recaptime.eu.org {
101-
import globals cf_dns01_challenge
102-
103-
@proxyparty host proxyparty.recaptime.dev proxyparty.recaptime.eu.org
104-
105-
handle @proxyparty {
106-
redir https://gitlab.com/recaptime-dev/infra/proxyparty-caddy
107-
}
108-
109-
redir https://recaptime.dev
110-
}
111-
## RecapTime.dev project domains - END ##
67+
# Import all the Caddyfiles in the projects subdirectory
68+
import "./projects/*.Caddyfile"
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
*.recaptime.dev, *.recaptime.eu.org {
2+
import globals cf_dns01_challenge
3+
4+
@proxyparty host proxyparty.recaptime.dev proxyparty.recaptime.eu.org
5+
6+
handle @proxyparty {
7+
redir https://gitlab.com/recaptime-dev/infra/proxyparty-caddy
8+
}
9+
10+
redir https://recaptime.dev
11+
}
12+
13+
*.lorebooks.wiki, *.beta.lorebooks.wiki, *.lorebooks.eu.org, *.beta.lorebooks.eu.org {
14+
import globals cf_dns01_challenge
15+
16+
@proxyparty host proxyparty.lorebooks.wiki proxyparty.lorebooks.eu.org
17+
@ajhalili2006 host ajhalili2006.lorebooks.wiki ajhalili2006.lorebooks.eu.org andreijiroh.lorebooks.wiki andreijiroh.lorebooks.eu.org
18+
19+
handle @proxyparty {
20+
redir https://gitlab.com/recaptime-dev/infra/proxyparty-caddy
21+
}
22+
23+
handle @ajhalili2006 {
24+
redir https://wiki.andreijiroh.dev{path}
25+
}
26+
27+
handle {
28+
root * ./pages/parking.lorebooks.wiki
29+
encode gzip
30+
try_files {path} /index.html
31+
file_server
32+
}
33+
}
34+
35+
*.stellapent.wiki stellapent.wiki {
36+
import globals cf_dns01_challenge
37+
38+
handle {
39+
root * ./pages/parking.lorebooks.wiki
40+
encode gzip
41+
try_files {path} /index.html
42+
file_server
43+
}
44+
}

0 commit comments

Comments
 (0)