Merge branch 'hotfix_broken_likes' into 'develop'
[akkoma] / installation / caddyfile-pleroma.example
1 social.domain.tld {
2 log /var/log/caddy/pleroma_access.log
3 errors /var/log/caddy/pleroma_error.log
4
5 gzip
6
7 proxy / localhost:4000 {
8 websocket
9 transparent
10 }
11
12 tls user@domain.tld {
13 # Remove the rest of the lines in here, if you want to support older devices
14 key_type p256
15 ciphers ECDHE-ECDSA-WITH-CHACHA20-POLY1305 ECDHE-RSA-WITH-CHACHA20-POLY1305 ECDHE-ECDSA-AES256-GCM-SHA384 ECDHE-RSA-AES256-GCM-SHA384 ECDHE-ECDSA-AES128-GCM-SHA256 ECDHE-RSA-AES128-GCM-SHA256
16 }
17
18 header / {
19 X-XSS-Protection "1; mode=block"
20 X-Frame-Options "DENY"
21 X-Content-Type-Options "nosniff"
22 Referrer-Policy "same-origin"
23 Strict-Transport-Security "max-age=31536000; includeSubDomains;"
24 Expect-CT "enforce, max-age=2592000"
25 }
26
27 # If you do not want remote frontends to be able to access your Pleroma backend server, remove these lines.
28 # If you want to allow all origins access, remove the origin lines.
29 # To use this directive, you need the http.cors plugin for Caddy.
30 cors / {
31 origin https://halcyon.domain.tld
32 origin https://pinafore.domain.tld
33 methods POST,PUT,DELETE,GET,PATCH,OPTIONS
34 allowed_headers Authorization,Content-Type,Idempotency-Key
35 exposed_headers Link,X-RateLimit-Reset,X-RateLimit-Limit,X-RateLimit-Remaining,X-Request-Id
36 }
37 # Stop removing lines here.
38
39 # If you do not want to use the mediaproxy function, remove these lines.
40 # To use this directive, you need the http.cache plugin for Caddy.
41 cache {
42 match_path /proxy
43 default_max_age 720m
44 }
45 # Stop removing lines here.
46 }