-
Notifications
You must be signed in to change notification settings - Fork 0
Caddy
Dr. Thomas Jansen edited this page Aug 9, 2023
·
2 revisions
If you are using Caddy web server, add the following directive to your Caddyfile
file:
respond /.git* 403
If you want to return a 404
HTTP status code instead of 403
, use the following instead:
respond /.git* 404
Don't forget to restart Caddy after making the change, e.g. on Debian:
sudo systemctl restart caddy