Ben's notes

Linux, Unix, network, radio...

User Tools

Site Tools


wireguard_apu_ubuntu

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
wireguard_apu_ubuntu [2019/02/24 16:39] adminwireguard_apu_ubuntu [2019/02/24 18:21] admin
Line 48: Line 48:
  
 WGINT=$1 WGINT=$1
-OUTINT=enp2s0+OUTINT=enp1s0
 ACTION=$2 ACTION=$2
  
Line 72: Line 72:
 echo "net.ipv4.ip_forward=1" >> /etc/sysctl.d/forward.conf echo "net.ipv4.ip_forward=1" >> /etc/sysctl.d/forward.conf
 sysctl -p /etc/sysctl.d/forward.conf</code> sysctl -p /etc/sysctl.d/forward.conf</code>
-  * Allow firewall:<code>ufw allow 20617/udp</code> 
   * Start interface:<code>wg-quick up wg0</code>   * Start interface:<code>wg-quick up wg0</code>
   * Enable the interface at boot:<code>systemctl enable wg-quick@wg0</code>   * Enable the interface at boot:<code>systemctl enable wg-quick@wg0</code>
Line 97: Line 96:
 qrencode -t ansiutf8 < wg-client1.conf</code> qrencode -t ansiutf8 < wg-client1.conf</code>
   * Add peer to server:<code>   * Add peer to server:<code>
-wg set wg0 peer $(cat publickey-${CLIENT}) allowed-ips 0.0.0.0/0+wg set wg0 peer $(cat publickey-${CLIENT}) allowed-ips 192.168.2.2/32
 </code> </code>
  
 {{tag>[wireguard vpn apu apu1 apu2 Ubuntu linux ]}} {{tag>[wireguard vpn apu apu1 apu2 Ubuntu linux ]}}
wireguard_apu_ubuntu.txt · Last modified: 2021/10/09 15:14 by 127.0.0.1