Conversation
There was a problem hiding this comment.
Pull request overview
Updates the Defguard Gateway OPNsense plugin and gateway service metadata to align with Defguard Gateway 2.0 configuration, notably shifting to the new grpc_port/cert_dir-based setup.
Changes:
- Update gateway CLI/version reporting and build metadata/dependencies for 2.0.0.
- Revise OPNsense plugin model/form/template to match Gateway 2.0 config options (e.g.,
grpc_port,cert_dir, firewall/health options). - Improve OPNsense UI flow by adding an explicit Stop action and gating restart on successful reconfigure.
Reviewed changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
src/config.rs |
Uses the crate VERSION (incl. git SHA) for clap version output. |
build.rs |
Adjusts vergen git2 emission to only include SHA. |
Cargo.toml |
Bumps clap and defguard git dependencies; simplifies vergen-git2 spec. |
Cargo.lock |
Lockfile updates for dependency bumps (toml, winnow, defguard git rev, etc.). |
opnsense/src/opnsense/service/templates/OPNsense/DefguardGateway/config.toml |
Reworks generated config for Gateway 2.0 fields (grpc_port, cert_dir, etc.). |
opnsense/src/opnsense/mvc/app/views/OPNsense/DefguardGateway/index.volt |
Adds Stop button and restart gating after reconfigure. |
opnsense/src/opnsense/mvc/app/models/OPNsense/DefguardGateway/DefguardGateway.xml |
Updates the plugin model fields/validation for new Gateway 2.0 options. |
opnsense/src/opnsense/mvc/app/controllers/OPNsense/DefguardGateway/forms/general.xml |
Updates the UI form fields to match the updated model/config template. |
opnsense/src/etc/inc/plugins.inc.d/defguardgateway.inc |
Aligns enabled flag naming and tightens device regex to the selected interface. |
opnsense/Makefile |
Bumps plugin version to 2.0.0. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
opnsense/src/opnsense/mvc/app/models/OPNsense/DefguardGateway/DefguardGateway.xml
Show resolved
Hide resolved
opnsense/src/opnsense/mvc/app/models/OPNsense/DefguardGateway/DefguardGateway.xml
Show resolved
Hide resolved
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
t-aleksander
approved these changes
Mar 18, 2026
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.
#239