Files
vpn/configs/ru-vds/postdown.sh

18 lines
464 B
Bash
Raw Normal View History

2026-02-02 20:11:05 +03:00
#!/bin/bash
#
# PostDown script for WireGuard wg0 interface
# Pure nftables solution - no iptables/ipset dependencies
#
2026-02-02 20:11:05 +03:00
# Remove policy routing rule
ip rule del from 10.10.0.0/24 fwmark 0x1 table proxy priority 100 2>/dev/null || true
# Flush routing table
ip route flush table proxy 2>/dev/null || true
# Flush nftables vpn-routing table (keeps filter and nat rules intact)
nft flush table ip vpn-routing 2>/dev/null || true
2026-02-02 20:11:05 +03:00
echo "PostDown script completed"