Caddyfile 1023 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. # Dashboard
  2. https://dashboard.{$NM_DOMAIN} {
  3. # Apply basic security headers
  4. header {
  5. # Enable cross origin access to *.{$NM_DOMAIN}
  6. Access-Control-Allow-Origin *.{$NM_DOMAIN}
  7. # Enable HTTP Strict Transport Security (HSTS)
  8. Strict-Transport-Security "max-age=31536000;"
  9. # Enable cross-site filter (XSS) and tell browser to block detected attacks
  10. X-XSS-Protection "1; mode=block"
  11. # Disallow the site to be rendered within a frame on a foreign domain (clickjacking protection)
  12. X-Frame-Options "SAMEORIGIN"
  13. # Prevent search engines from indexing
  14. X-Robots-Tag "none"
  15. # Remove the server name
  16. -Server
  17. }
  18. reverse_proxy http://netmaker-ui
  19. }
  20. # API
  21. https://api.{$NM_DOMAIN} {
  22. reverse_proxy http://netmaker:8081
  23. }
  24. # TURN
  25. https://turn.{$NM_DOMAIN} {
  26. reverse_proxy host.docker.internal:3479
  27. }
  28. # TURN API
  29. https://turnapi.{$NM_DOMAIN} {
  30. reverse_proxy http://host.docker.internal:8089
  31. }
  32. # MQ
  33. wss://broker.{$NM_DOMAIN} {
  34. reverse_proxy ws://mq:8883 # For EMQX websockets use `reverse_proxy ws://mq:8083`
  35. }