]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
distro/pkg/rpm: use noreplace for config.yaml
authorOto Šťáva <oto.stava@nic.cz>
Tue, 2 Apr 2024 09:29:29 +0000 (11:29 +0200)
committerOto Šťáva <oto.stava@nic.cz>
Tue, 2 Apr 2024 10:34:17 +0000 (12:34 +0200)
Adds `%config(noreplace)` to `config.yaml`. This prevents the package
from overwriting the user's edited configuration upon update, and
instead adds the new default configuration as a `.rpmnew` file for the
user to potentially consider.

distro/pkg/rpm/knot-resolver.spec

index 2ba5383ad6666c5654db9d1ee84baed5b368b54b..95d8af5205fe4e1bdd8ebd4df3a53a135d942a70 100644 (file)
@@ -345,7 +345,7 @@ getent passwd knot-resolver >/dev/null || useradd -r -g knot-resolver -d %{_sysc
 
 %files -n knot-resolver-manager
 %{python3_sitearch}/knot_resolver_manager*
-%{_sysconfdir}/knot-resolver/config.yaml
+%config(noreplace) %{_sysconfdir}/knot-resolver/config.yaml
 %{_unitdir}/knot-resolver.service
 %{_bindir}/kresctl
 %{_bindir}/knot-resolver