dn42-ansible/mkpeerpsk.sh

7 lines
153 B
Bash
Raw Normal View History

2025-01-25 23:43:41 +00:00
#!/bin/bash
set -x
cd /etc/systemd/network && \
wg genpsk > "$1".psk && \
chmod o-rwx "$1".psk && \
chown root:systemd-network "$1".psk && \
cat "$1".psk