mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
security/netbird: Fix service startup and add syslog support (#4942)
* add syslog configuration options and update service reconfiguration endpoint * enable syslog by default and expand log level options * add plugin revision * update service configuration and logging options * update syslog log level options and change config sync target * revert default config file * Fix log level settings * refactor * Update security/netbird/Makefile Co-authored-by: Franco Fichtner <franco@lastsummer.de> * Update security/netbird/src/opnsense/service/templates/OPNsense/Netbird/netbird Co-authored-by: Franco Fichtner <franco@lastsummer.de> * bump setting model version and use syslog always * Update security/netbird/src/opnsense/service/templates/OPNsense/Netbird/netbird Co-authored-by: Franco Fichtner <franco@lastsummer.de> --------- Co-authored-by: Franco Fichtner <franco@lastsummer.de>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
PLUGIN_NAME= netbird
|
||||
PLUGIN_VERSION= 1.0
|
||||
PLUGIN_VERSION= 1.1
|
||||
PLUGIN_DEPENDS= netbird
|
||||
PLUGIN_COMMENT= Peer-to-peer VPN that seamlessly connects your devices
|
||||
PLUGIN_MAINTAINER= dev@netbird.io
|
||||
|
||||
@@ -90,4 +90,14 @@
|
||||
<type>checkbox</type>
|
||||
<help>Enable Rosenpass permissive mode</help>
|
||||
</field>
|
||||
<field>
|
||||
<type>header</type>
|
||||
<label>Syslog Logging</label>
|
||||
</field>
|
||||
<field>
|
||||
<id>settings.syslog.logLevel</id>
|
||||
<label>Log Level</label>
|
||||
<type>dropdown</type>
|
||||
<help>Set the syslog logging level. Setting a certain log level will cause all messages of the specified and more severe log levels to be logged.</help>
|
||||
</field>
|
||||
</form>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<model>
|
||||
<mount>//OPNsense/netbird/settings</mount>
|
||||
<description>NetBird settings</description>
|
||||
<version>1.0.0</version>
|
||||
<version>1.1.0</version>
|
||||
<items>
|
||||
<general>
|
||||
<enable type="BooleanField">
|
||||
@@ -62,5 +62,19 @@
|
||||
<Required>Y</Required>
|
||||
</rosenpassPermissive>
|
||||
</postquantum>
|
||||
<syslog>
|
||||
<logLevel type="OptionField">
|
||||
<Required>Y</Required>
|
||||
<Default>info</Default>
|
||||
<OptionValues>
|
||||
<fatal>fatal</fatal>
|
||||
<error>error</error>
|
||||
<warn>warn</warn>
|
||||
<info>info</info>
|
||||
<debug>debug</debug>
|
||||
<trace>trace</trace>
|
||||
</OptionValues>
|
||||
</logLevel>
|
||||
</syslog>
|
||||
</items>
|
||||
</model>
|
||||
|
||||
@@ -54,4 +54,4 @@
|
||||
<div class="content-box">
|
||||
{{ partial("layout_partials/base_form",['fields':settingsForm,'id':'frmSettings']) }}
|
||||
</div>
|
||||
{{ partial('layout_partials/base_apply_button', {'data_endpoint': '/api/netbird/settings/sync', 'data_service_widget': 'netbird'}) }}
|
||||
{{ partial('layout_partials/base_apply_button', {'data_endpoint': '/api/netbird/service/reconfigure', 'data_service_widget': 'netbird'}) }}
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
{% if OPNsense.netbird.settings.general.enable == '1' %}
|
||||
netbird_enable="YES"
|
||||
netbird_setup="/usr/local/sbin/pluginctl -c netbird_sync_config"
|
||||
netbird_logfile="syslog"
|
||||
netbird_loglevel="{{ OPNsense.netbird.settings.syslog.logLevel }}"
|
||||
{% else %}
|
||||
netbird_enable="NO"
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user