sysutils/git-backup: not backing up new firewall rules
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 1.2k
- Forks
- 863
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 10
Description
Important notices
- I have read the contributing guidelines at https://github.com/opnsense/core/blob/master/CONTRIBUTING.md
- I am convinced that my issue is new after having checked both open and closed issues at https://github.com/opnsense/core/issues?q=is%3Aissue
Describe the bug
I just migrated legacy firewall rules to the new rules.
Git backup didn't produce a commit.
Clicking "Setup/Test Git" produced a new commit, but didn't include new rules and didn't remove legacy rules.
The commit diff only contains
<backup><git persisted_at="<new timestamp>">
<revision>
<description>/diag_backup.php made changes</description>
<time><changed timestamp></time>
To Reproduce
Steps to reproduce the behavior:
- migrate legacy firewall rules
- click "Setup/Test Git" in System > Configuration > Backups
- check backup
Expected behavior
Configuration changes should invoke Git backup and Git backup should include the changes
Additional context
This issue could be related to #10289
Git backup worked flawlessy before. The last backup commit was 17h ago.
I updated OPNSense to 26.1.8. Before it was the latest version available yesterday.
When I diff backup files created with "Download configuration" from before and after the rules migration, lots of removal and addition of rules are shown.
Environment
OPNsense 26.1.8 (amd64).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the System > Configuration > Backups “Setup/Test Git” entry point and the /diag_backup.php change noted in the issue. Reproduce the legacy-rule migration, compare configuration backups before and after it, and verify that the Git commit includes the new rules and removes the legacy rules rather than only updating the timestamp.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- git, php
- Domain
- devops, tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100