From ecd0f7cfa25632d4e0fb5419064698f1f968e3b7 Mon Sep 17 00:00:00 2001 From: Jeffrey Serio <hyperreal@moonshadow.dev> Date: Sun, 23 Mar 2025 12:16:43 -0500 Subject: [PATCH] fix grep/awk pipeline --- shell/natpmpcd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell/natpmpcd b/shell/natpmpcd index 83114bb..16ef5ee 100755 --- a/shell/natpmpcd +++ b/shell/natpmpcd @@ -1,6 +1,6 @@ #!/bin/sh -PORT=$(natpmpc -a 1 0 udp 60 -g 10.2.0.1 | awk '/Mapped public/ {print $4}') +PORT=$(natpmpc -a 1 0 udp 60 -g 10.2.0.1 | grep "Mapped public port" | awk '{print $4}') echo "$PORT" | tee /usr/local/etc/natvpn_port.txt while true; do