forked from skylines-project/skylines
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCaddyfile
72 lines (56 loc) · 1.44 KB
/
Caddyfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
# https://caddyserver.com configuration for the production server
skylines.aero {
log /home/skylines/log/caddy
root /home/skylines/src/skylines/frontend/static
gzip
header / Strict-Transport-Security "max-age=31536000;"
rewrite {
if {path} not_starts_with /api
if {path} not_starts_with /files
if {path} not_starts_with /client.php
if {path} not_starts_with /track.php
if {path} not_starts_with /widgets
if {path} not_starts_with /mapproxy
to {path} /
# if {path} not_starts_with /svg
# to maintenance.html
}
expires {
match ^/assets/.*\.css$ 1y
match ^/assets/.*\.js$ 1y
match ^/fonts 1y
match ^/mapproxy 7d
match .* 0s
}
proxy /api http://localhost:9115 {
transparent
}
proxy /files http://localhost:9115 {
transparent
}
proxy /client.php http://localhost:9115 {
transparent
}
proxy /track.php http://localhost:9115 {
transparent
}
proxy /widgets http://localhost:9115 {
transparent
}
proxy /mapproxy http://localhost:9109 {
transparent
without /mapproxy
}
}
www.skylines.aero {
redir https://skylines.aero{uri}
}
www02.skylines.aero {
redir https://skylines.aero{uri}
}
tracking.skylines.aero {
redir https://skylines.aero/tracking/
}
maps.skylines.aero {
redir https://skylines.aero{uri}
}