This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
linux:wireguard [2018/12/24 14:08] josep |
linux:wireguard [2018/12/24 14:14] josep |
||
---|---|---|---|
Line 12: | Line 12: | ||
Address = 192.168.99.1/24 | Address = 192.168.99.1/24 | ||
ListenPort = 51820 | ListenPort = 51820 | ||
- | PrivateKey = <server_private.key> | + | PrivateKey = <key_server_private.key> |
SaveConfig = false | SaveConfig = false | ||
Line 20: | Line 20: | ||
[Peer] | [Peer] | ||
#Client | #Client | ||
- | PublicKey = <client_public.key> | + | PublicKey = <key_client_public.key> |
AllowedIPs = 192.168.99.2/32 | AllowedIPs = 192.168.99.2/32 | ||
</code> | </code> | ||
Line 29: | Line 29: | ||
Address = 192.168.99.2/24 | Address = 192.168.99.2/24 | ||
DNS = 8.8.8.8,8.8.4.4 | DNS = 8.8.8.8,8.8.4.4 | ||
- | PrivateKey = <client_private.key> | + | PrivateKey = <key_client_private.key> |
[Peer] | [Peer] | ||
Endpoint = SERVER_HOSTNAME:51820 | Endpoint = SERVER_HOSTNAME:51820 | ||
- | PublicKey = <server_public.key> | + | PublicKey = <key_server_public.key> |
AllowedIPs = 0.0.0.0/0, ::/0 | AllowedIPs = 0.0.0.0/0, ::/0 | ||
PersistentKeepalive = 25 | PersistentKeepalive = 25 | ||
+ | </code> | ||
+ | |||
+ | Last steps: | ||
+ | <code> | ||
+ | sudo wg-quick up wg0 | ||
+ | sudo wg | ||
+ | sudo systemctl enable wg-quick@wg0 | ||
</code> | </code> | ||