Release v1.1.0
This commit is contained in:
1 parent
34227efd2b
commit
edc710cbd2
46 files changed
+5324
-190
No files matched your search
@@ -0,0 +1,6 @@
|
||||
-- 0004_interface_roles.sql
|
||||
-- Explicit WireGuard Interface Role: Overlay (primary client network) or Upstream (third-party VPN tunnel)
|
||||
|
||||
ALTER TABLE interfaces ADD COLUMN role TEXT NOT NULL DEFAULT 'overlay' CHECK (role IN ('overlay', 'upstream'));
|
||||
|
||||
UPDATE interfaces SET role = 'overlay' WHERE role IS NULL OR role = '';
|
||||
@@ -0,0 +1,34 @@
|
||||
------------------------------------------------------------------------
|
||||
-- nx9-wg SQLite Migration (0005_optional_listen_port.sql)
|
||||
-- Allow nullable listen_port for Upstream interfaces with dynamic ports
|
||||
------------------------------------------------------------------------
|
||||
PRAGMA foreign_keys = OFF;
|
||||
|
||||
CREATE TABLE interfaces_dg_tmp (
|
||||
id TEXT PRIMARY KEY,
|
||||
name TEXT NOT NULL UNIQUE,
|
||||
role TEXT NOT NULL DEFAULT 'overlay' CHECK (role IN ('overlay', 'upstream')),
|
||||
private_key TEXT NOT NULL,
|
||||
public_key TEXT NOT NULL,
|
||||
listen_port INTEGER,
|
||||
ipv4_cidr TEXT NOT NULL,
|
||||
ipv6_cidr TEXT,
|
||||
mtu INTEGER,
|
||||
dns TEXT,
|
||||
enabled INTEGER NOT NULL DEFAULT 1,
|
||||
pre_up TEXT,
|
||||
post_up TEXT,
|
||||
pre_down TEXT,
|
||||
post_down TEXT,
|
||||
created_at TEXT NOT NULL DEFAULT (datetime('now')),
|
||||
updated_at TEXT NOT NULL DEFAULT (datetime('now'))
|
||||
);
|
||||
|
||||
INSERT INTO interfaces_dg_tmp (id, name, role, private_key, public_key, listen_port, ipv4_cidr, ipv6_cidr, mtu, dns, enabled, pre_up, post_up, pre_down, post_down, created_at, updated_at)
|
||||
SELECT id, name, role, private_key, public_key, listen_port, ipv4_cidr, ipv6_cidr, mtu, dns, enabled, pre_up, post_up, pre_down, post_down, created_at, updated_at FROM interfaces;
|
||||
|
||||
DROP TABLE interfaces;
|
||||
ALTER TABLE interfaces_dg_tmp RENAME TO interfaces;
|
||||
CREATE INDEX idx_interfaces_name ON interfaces(name);
|
||||
|
||||
PRAGMA foreign_keys = ON;
|
||||
Reference in new issue
Block a user