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

Caddyfile An error occurs when adding log configurations #6741

Closed
puzhengwu opened this issue Dec 10, 2024 · 1 comment
Closed

Caddyfile An error occurs when adding log configurations #6741

puzhengwu opened this issue Dec 10, 2024 · 1 comment
Labels
question ❔ Help is being requested

Comments

@puzhengwu
Copy link

2.8.4 + dns.providers.alidns

log {
output file /var/log/caddy/log.log
format json
}

caddy reload --config /etc/caddy/Caddyfile
2024/12/10 09:07:06.607 INFO using config from file {"file": "/etc/caddy/Caddyfile"}
2024/12/10 09:07:06.610 INFO adapted config to JSON {"adapter": "caddyfile"}
Error: sending configuration to instance: caddy responded with error: HTTP 400: {"error":"loading config: loading new config: loading http app module: decoding module config: http: json: cannot unmarshal array into Go struct field ServerLogConfig.servers.logs.logger_names of type string"}

@francislavoie
Copy link
Member

You probably didn't restart Caddy after rebuilding the new version. The running Caddy is still your old version.

@mholt mholt closed this as completed Dec 10, 2024
@mholt mholt added the question ❔ Help is being requested label Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question ❔ Help is being requested
Projects
None yet
Development

No branches or pull requests

3 participants