If you’re using git to version Caddy configuration, you can use a pre-commit hook to test it, ensuring that you’ll never have invalid configuration. That’s what I do.
caddy --validate
There’s some extra command args that may be necessary but that should be an adequate first step.
If you’re using git to version Caddy configuration, you can use a pre-commit hook to test it, ensuring that you’ll never have invalid configuration. That’s what I do.
There’s some extra command args that may be necessary but that should be an adequate first step.