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

strongswan: preserve changed configuration files #25920

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lowjoel
Copy link
Contributor

@lowjoel lowjoel commented Feb 8, 2025

After reinstalling the packages with the preserved configuration files after a sysupgrade, the reinstalled package config files overwrite what is on disk rather than being placed as conf-opkg. Defining these config files will preserve them appropriately.

Maintainer: @pprindeville @Thermi
Compile tested: aarch64, Linksys E8450, OpenWrt 24.10.0
Run tested: aarch64, Linksys E8450, OpenWrt 24.10.0

Description:
This adds the config files to the conffiles target which should signal to opkg (and apk in future) the config files to be left alone if they exist.

I have checked that the resulting opkg package's control.tar.gz has a new conffiles metadata file. Installing the package now shows this message:

# opkg install /tmp/strongswan-mod-dhcp_5.9.14-r7_aarch64_cortex-a53.ipk
Upgrading strongswan-mod-dhcp on root from 5.9.14-r6 to 5.9.14-r7...
Configuring strongswan-mod-dhcp.
Collected errors:
 * resolve_conffiles: Existing conffile /etc/strongswan.d/charon/dhcp.conf is different from the conffile in the new package. The new conffile will be placed at /etc/strongswan.d/charon/dhcp.conf-opkg.

After reinstalling the packages with the preserved configuration files
after a sysupgrade, the reinstalled package config files overwrite what
is on disk rather than being placed as conf-opkg. Defining these config
files will preserve them appropriately.

Signed-off-by: Joel Low <[email protected]>
@lowjoel lowjoel force-pushed the strongswan-preserve-configs branch from 54adf29 to aff5c6c Compare February 8, 2025 08:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant