Repository navigation
feat: add reusable source lists with nesting and RFC1918 preset - #5
Merged
Merged
Conversation
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.
This pull request introduces a major new feature: reusable source lists for jobs, allowing sets of hostnames, IPs, CIDRs, and nested source references to be defined once and included in multiple jobs. The implementation includes database schema changes, new store logic for managing source lists, API and workflow documentation updates, and CI workflow extensions for Node.js-based UI tests. Below are the most important changes grouped by theme.
Reusable Source Lists Feature
SourceListtype and comprehensive management logic ininternal/store/source_lists.go, supporting creation, update, deletion (with cycle and reference checks), and expansion of nested source lists. This includes logic to prevent cycles, block deletion of referenced sources, and ensure atomic updates with locking and transactions.SyncJobstruct and related database logic to support anincluded_list_idsfield, enabling jobs to reference reusable source lists in addition to inline entries. This includes schema migration, read/write logic, and validation. [1] [2] [3] [4] [5] [6]sourceMu) to serialize source list and job reference mutations for data integrity. [1] [2]Documentation Updates
README.mdto document reusable source lists, including their usage, API endpoints, cycle prevention, RFC1918 preset, and operational details. The API section now describes CRUD endpoints for source lists and updates to job/resolve endpoints for including source lists. [1] [2] [3] [4] [5] [6]Continuous Integration
.github/workflows/ci.yml) to set up Node.js 24 and run syntax and test checks for the UI's reusable source list functionality.These changes collectively enable robust, reusable, and composable source management for jobs, improving maintainability, safety, and flexibility of input management.
Closes #3