autorestic
autorestic copied to clipboard
Check and init command ignore YAML options
When running autorestic check
, at some point, autorestic runs restic check
. However, any option in the YAML configuration file won't be passed to restic
. Only environment is included. The code is here : https://github.com/cupcakearmy/autorestic/blob/3bc091f826704d0a95d4d500d60083bddd3dee74/internal/backend.go#L122-L124
A few lines later, restic init
won't use YAML options neither.
Example configuration file:
backends:
rest:
[...]
options:
all:
cacert:
- /var/lib/restic/certs/ca/ca_cert.pem
tls-client-cert:
- /var/lib/restic/certs/client_cert_with_key.pem
In that case TLS options are ignored and the command fails with an unknown certificate
error.
Thanks for reporting and fixing it. I hope I get to review it soon!
My issue here https://github.com/cupcakearmy/autorestic/issues/147#issuecomment-1166202685 may be a result of this bug. @cupcakearmy I know you asked for patience. Hope this one here can be prioritized when you find the time to work on this project again. Thank you!
@cupcakearmy Just a little ping if you have the time to look this PR. :)