aboutsummaryrefslogtreecommitdiffstats
path: root/src/slskd/Integrations/VPN
diff options
context:
space:
mode:
authorJP Dillingham <jp@dillingham.me>2026-03-15 18:01:53 -0500
committerGitHub <noreply@github.com>2026-03-15 18:01:53 -0500
commit92c5d4c6b30075451a0a85e28981e794964c48d1 (patch)
tree1e558bb6b115bd11136981b280c1be23e1151132 /src/slskd/Integrations/VPN
parent032d9a3513642b85379c6b33a479cb7e0a5adc22 (diff)
parent81ad3c08618eed605c0d2e89cfee1d9d4d696490 (diff)
downloadslskd-92c5d4c6b30075451a0a85e28981e794964c48d1.tar.gz
Merge pull request #1672 from slskd/options
BREAKING: Move all transfer options under a 'transfers' key
Diffstat (limited to 'src/slskd/Integrations/VPN')
-rw-r--r--src/slskd/Integrations/VPN/Clients/Gluetun.cs6
-rw-r--r--src/slskd/Integrations/VPN/VPNService.cs8
2 files changed, 7 insertions, 7 deletions
diff --git a/src/slskd/Integrations/VPN/Clients/Gluetun.cs b/src/slskd/Integrations/VPN/Clients/Gluetun.cs
index d22c15f7..136c9c05 100644
--- a/src/slskd/Integrations/VPN/Clients/Gluetun.cs
+++ b/src/slskd/Integrations/VPN/Clients/Gluetun.cs
@@ -26,7 +26,7 @@ using System.Net.Http.Json;
using System.Text.Json.Serialization;
using System.Threading.Tasks;
using Serilog;
-using static slskd.Options.IntegrationOptions.VpnOptions;
+using static slskd.Options.IntegrationsOptions.VpnOptions;
/// <summary>
/// Gluetun VPN client.
@@ -47,7 +47,7 @@ public class Gluetun : IVPNClient
private ILogger Log { get; } = Serilog.Log.ForContext<Gluetun>();
private IHttpClientFactory HttpClientFactory { get; }
private IOptionsMonitor<Options> OptionsMonitor { get; }
- private GluetunVpnOptions Options => OptionsMonitor.CurrentValue.Integration.Vpn.Gluetun;
+ private GluetunVpnOptions Options => OptionsMonitor.CurrentValue.Integrations.Vpn.Gluetun;
/// <summary>
/// Fetch the VPN connection status from the Gluetun control server.
@@ -85,7 +85,7 @@ public class Gluetun : IVPNClient
int? port = null;
- if (OptionsMonitor.CurrentValue.Integration.Vpn.PortForwarding)
+ if (OptionsMonitor.CurrentValue.Integrations.Vpn.PortForwarding)
{
port = (await MakeRequest<GluetunPortForwardResponse>(http, "/v1/portforward"))?.Port;
diff --git a/src/slskd/Integrations/VPN/VPNService.cs b/src/slskd/Integrations/VPN/VPNService.cs
index db09c041..c0a65f00 100644
--- a/src/slskd/Integrations/VPN/VPNService.cs
+++ b/src/slskd/Integrations/VPN/VPNService.cs
@@ -52,9 +52,9 @@ public class VPNService : IDisposable
SoulseekClient = soulseekClient;
HttpClientFactory = httpClientFactory;
- if (OptionsAtStartup.Integration.Vpn.Enabled)
+ if (OptionsAtStartup.Integrations.Vpn.Enabled)
{
- Timer = new System.Timers.Timer(interval: OptionsAtStartup.Integration.Vpn.PollingInterval)
+ Timer = new System.Timers.Timer(interval: OptionsAtStartup.Integrations.Vpn.PollingInterval)
{
AutoReset = true,
};
@@ -63,7 +63,7 @@ public class VPNService : IDisposable
// detect VPN based on the configuration provided; this logic will determine the order
// we can revisit this if/when we add other options besides gluetun
- if (!string.IsNullOrEmpty(OptionsMonitor.CurrentValue.Integration.Vpn.Gluetun.Url))
+ if (!string.IsNullOrEmpty(OptionsMonitor.CurrentValue.Integrations.Vpn.Gluetun.Url))
{
Client = new Gluetun(HttpClientFactory, OptionsMonitor);
@@ -154,7 +154,7 @@ public class VPNService : IDisposable
throw new VPNClientException("VPN client not properly initialized; something went seriously wrong! Please report to GitHub.");
}
- var options = OptionsMonitor.CurrentValue.Integration.Vpn;
+ var options = OptionsMonitor.CurrentValue.Integrations.Vpn;
bool isReadyNow = false;
VPNStatus status = new VPNStatus();