Последняя активность 1 month ago

gistfile1.txt Исходник
1wgctl test --section destructive --verbose
2
3────────────────────────────────────────────────
4 wgctl Test Suite
5────────────────────────────────────────────────
6
7 Destructive (modifying state)
8 ──────────────────────────────────────────────────
9 ❌ add phone peer
10 Output: => ERROR: ❌ Client already exists: phone-testunit
11root@wireguard:/etc/wireguard/wgctl# wgctl rm --name phone-testunit
12Are you sure you want to permanently remove 'phone-testunit'? [y/N] y
13
14────────────────────────────────────────────────
15 Removing client: phone-testunit
16────────────────────────────────────────────────
17=> INFO: 🔑 🔒 Removed keys for: phone-testunit
18=> SUCCESS: ✅ 🔒 Client removed: phone-testunit
19root@wireguard:/etc/wireguard/wgctl# wgctl test --section destructive --verbose
20
21────────────────────────────────────────────────
22 wgctl Test Suite
23────────────────────────────────────────────────
24
25 Destructive (modifying state)
26 ──────────────────────────────────────────────────
27 ✅ add phone peer
28 ✅ block peer
29 ✅ list shows blocked
30 ✅ unblock peer
31 ✅ rule assign
32 ✅ rule unassign
33 ❌ group add
34 Output: => ERROR: ❌ Group already exists: testgroup
35root@wireguard:/etc/wireguard/wgctl# wgctl rm --name phone-testunit
36Are you sure you want to permanently remove 'phone-testunit'? [y/N] y
37
38────────────────────────────────────────────────
39 Removing client: phone-testunit
40────────────────────────────────────────────────
41=> INFO: 🔑 🔒 Removed keys for: phone-testunit
42=> SUCCESS: ✅ 🔒 Client removed: phone-testunit
43root@wireguard:/etc/wireguard/wgctl# /usr/local/bin/wgctl group unblock --name testgroup 2>&1
44root@wireguard:/etc/wireguard/wgctl# /usr/local/bin/wgctl group rm --name testgroup 2>&1
45Remove group 'testgroup'? This only removes the group definition, not the peers. [y/N] y
46=> SUCCESS: ✅ 🔒 Group removed: testgroup
47root@wireguard:/etc/wireguard/wgctl# wgctl test --section destructive --verbose
48
49────────────────────────────────────────────────
50 wgctl Test Suite
51────────────────────────────────────────────────
52
53 Destructive (modifying state)
54 ──────────────────────────────────────────────────
55 ✅ add phone peer
56 ✅ block peer
57 ✅ list shows blocked
58 ✅ unblock peer
59 ✅ rule assign
60 ✅ rule unassign
61 ✅ group add
62 ✅ group peer add
63 ❌ group block (expected 'Blocked' in output)
64root@wireguard:/etc/wireguard/wgctl#