Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nixos/caddy: resync with upstream unit file #78360

Merged
merged 1 commit into from Feb 13, 2020

Conversation

yorickvP
Copy link
Contributor

@yorickvP yorickvP commented Jan 23, 2020

Motivation for this change

On ACME failure, instantly restarting Caddy will consume the rate limit within
10 seconds. Give the user a chance to resolve the failure.

Update the caddy service with some changes from upstream.

Things done

@mkaito
Copy link
Contributor

mkaito commented Jan 23, 2020

Oh yeah. This. The reason I never upstreamed this is that the unit restart timer isn't at fault. Caddy itself retries without restarting.

@yorickvP yorickvP changed the title nixos/caddy: wait 5 minutes between automatic restarts nixos/caddy: resync with upstream unit file Jan 23, 2020
StartLimitInterval = 86400;
StartLimitBurst = 5;
Restart = "on-abnormal";
StartLimitIntervalSec = 14400;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have my doubts that this will help. If Caddy retries internally, how is sytemd supposed to do anything about it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It won't help our SSL issue, but it's still useful to get the defaults from upstream.

@flokli flokli merged commit 7564f4f into NixOS:master Feb 13, 2020
karmanyaahm pushed a commit to karmanyaahm/nixos-ipfs-caddy-web-server that referenced this pull request Feb 21, 2023
(i know it shouldn't be panicing in the first place
but i'll debug that soon)
See https://caddyserver.com/docs/command-line#exit-codes

Caddy *should* restart when exiting with error code 2 or 3 or smth
Bug introduced in NixOS/nixpkgs#78360
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants