Repository navigation
feat(cli): automatic periodic SQLite export with retention - #8819
Merged
Merged
Conversation
Add an opt-in CLI that exports each user's database to `data/users/<user>/sqlite-backups/<YYYYMMDDTHHMMSSZ>.sqlite` (UTC) and prunes older files to a configured count. Gated by two new settings, `auto_sqlite_export.enabled` and `auto_sqlite_export.retention`. Kept separate from `cli/db-backup.php` / `cli/db-restore.php`, which stay the fixed-filename migration tool. First step of FreshRSS#8183.
polybjorn
force-pushed
the
feat/auto-sqlite-export
branch
from
May 11, 2026 21:48
ee891e3 to
ff38aa1
Compare
polybjorn
marked this pull request as ready for review
May 11, 2026 21:49
Member
|
Good idea 👍🏻 |
doonga
pushed a commit
to greyrock-labs/home-ops
that referenced
this pull request
May 20, 2026
This PR contains the following updates: | Package | Update | Change | |---|---|---| | [freshrss/freshrss](https://freshrss.org/) ([source](https://github.com/FreshRSS/FreshRSS)) | patch | `1.29.0-alpine` → `1.29.1-alpine` | --- >⚠️ **Warning** > > Some dependencies could not be looked up. Check the [Dependency Dashboard](issues/34) for more information. --- ### Release Notes <details> <summary>FreshRSS/FreshRSS (freshrss/freshrss)</summary> ### [`v1.29.1`](https://github.com/FreshRSS/FreshRSS/blob/HEAD/CHANGELOG.md#2026-05-20-FreshRSS-1291) [Compare Source](FreshRSS/FreshRSS@1.29.0...1.29.1) - Features - Accept `.txt` import of feed URLs in additional to e.g. OPML [#​8818](FreshRSS/FreshRSS#8818), [#​8837](FreshRSS/FreshRSS#8837) - New CLI for automatic periodic SQLite export with retention [#​8819](FreshRSS/FreshRSS#8819) - More feed info: last received date, publication date [#​8799](FreshRSS/FreshRSS#8799) - Bug fixing - Fix cookies with some browsers [#​8867](FreshRSS/FreshRSS#8867) - Fix search in shared user queries with empty results [#​8863](FreshRSS/FreshRSS#8863) - Fix XML errors with loading invalid OPML in `lib_opml` library [#​8652](FreshRSS/FreshRSS#8652), [#​8853](FreshRSS/FreshRSS#8853), [lib\_opml#48](https://framagit.org/marienfressinaud/lib_opml/-/merge_requests/48), [lib\_opml#51](https://framagit.org/marienfressinaud/lib_opml/-/merge_requests/51) - Fix ensure maximum number of feeds also with Dynamic OPML [#​8832](FreshRSS/FreshRSS#8832) - Fix click mark as read [#​8817](FreshRSS/FreshRSS#8817) - UI - Improve browser compatibility to keep mobile navigation at the bottom [#​8833](FreshRSS/FreshRSS#8833) - Improve support of older/simpler Web browsers/engines such as SeaMonkey [#​8810](FreshRSS/FreshRSS#8810), [#​8811](FreshRSS/FreshRSS#8811), [#​8813](FreshRSS/FreshRSS#8813), - Improve *Swage* theme [#​8842](FreshRSS/FreshRSS#8842) - Rename *Nord theme* to *Nord* [#​8805](FreshRSS/FreshRSS#8805) - Replace GIF spinner by CSS spinner [#​8804](FreshRSS/FreshRSS#8804), [#​8812](FreshRSS/FreshRSS#8812) - Various UI and style improvements: [#​8800](FreshRSS/FreshRSS#8800), [#​8816](FreshRSS/FreshRSS#8816), - I18n - Improve Brazilian Portuguese [#​8846](FreshRSS/FreshRSS#8846) - Improve Dutch [#​8868](FreshRSS/FreshRSS#8868) - Improve German [#​8840](FreshRSS/FreshRSS#8840) - Improve Polish [#​8854](FreshRSS/FreshRSS#8854) - Improve Russian [#​8861](FreshRSS/FreshRSS#8861) - Improve Traditional Chinese [#​8849](FreshRSS/FreshRSS#8849) - Misc. - Update dev dependencies [#​8858](FreshRSS/FreshRSS#8858), [#​8864](FreshRSS/FreshRSS#8864) </details> --- ### Configuration 📅 **Schedule**: (in timezone America/New_York) - Branch creation - At any time (no schedule defined) - Automerge - At any time (no schedule defined) 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4xODIuMiIsInVwZGF0ZWRJblZlciI6IjQzLjE4Mi4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJyZW5vdmF0ZS9jb250YWluZXIiLCJ0eXBlL3BhdGNoIl19--> Reviewed-on: https://git.greyrock.io/greyrock-labs/home-ops/pulls/88
2 of 8 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
First step of the multi-PR plan in #8183: settings and CLI for periodic on-server SQLite export. No Web UI yet.
Kept separate from
cli/db-backup.php/cli/db-restore.php. Those are paired around a fixedbackup.sqlitefilename for one-shot migration; periodic exports want timestamped files and rotation, so they live under their own pathdata/users/<user>/sqlite-backups/.Settings
Added to
config.default.php:enableddefaults tofalse; the CLI exits without writing when off.retentionis how many past backups to keep per user; older ones are deleted after each successful export.The third setting from #8183 (max DB size for a Web UI trigger) is deferred to the PR that adds the Web UI, since it has no consumer here.
Usage
./cli/export-sqlite-auto.php # Writes: data/users/<username>/sqlite-backups/<YYYYMMDDTHHMMSSZ>.sqliteTimestamps are UTC, basic ISO 8601 format, filename-safe and lexically sortable. Meant to be scheduled by the admin (cron, systemd timer). Supports
-q/--quietlike the other CLI scripts.Test plan
make test-allpasses locally.enabled => false: CLI exits 0, writes nothing.enabled => true: each user gets a.sqlitefile undersqlite-backups/containing all FreshRSS tables.retention => 3: 3 newest files remain per user.--quietsuppresses non-error output.