mirror of
https://github.com/pirate/wireguard-docs.git
synced 2025-10-03 22:36:17 +00:00
add full example wip
This commit is contained in:
1
full-example/laptop/laptop.key
Normal file
1
full-example/laptop/laptop.key
Normal file
@@ -0,0 +1 @@
|
||||
OPmibSXYAAcMIYKNsWqr77zY06Kl750AEB1nWQi1T2o=
|
1
full-example/laptop/laptop.key.pub
Normal file
1
full-example/laptop/laptop.key.pub
Normal file
@@ -0,0 +1 @@
|
||||
BV5DjXeCugIrjvEZLo4sZ0hN5wveFTH8kOfZ1AIQ5js=
|
9
full-example/laptop/setup.sh
Normal file
9
full-example/laptop/setup.sh
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
|
||||
# install wireguard on Ubuntu
|
||||
#add-apt-repository ppa:wireguard/wireguard
|
||||
#apt update
|
||||
#apt install wireguard
|
||||
|
||||
# install wireguard on macOS
|
||||
brew install wireguard-tools
|
5
full-example/laptop/start.sh
Normal file
5
full-example/laptop/start.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
PEER_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
wg-quick up "$PEER_DIR"/wg0.conf
|
||||
wg show
|
5
full-example/laptop/stop.sh
Normal file
5
full-example/laptop/stop.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
PEER_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
wg-quick down "$PEER_DIR"/wg0.conf
|
||||
wg show
|
13
full-example/laptop/wg0.conf
Normal file
13
full-example/laptop/wg0.conf
Normal file
@@ -0,0 +1,13 @@
|
||||
[Interface]
|
||||
# Name = laptop.example-vpn.dev
|
||||
Address = 10.0.0.4/32
|
||||
PrivateKey = <private key for laptop.example-vpn.dev>
|
||||
DNS = 1.1.1.1
|
||||
|
||||
[Peer]
|
||||
# Name = public-server1.example-vpn.tld
|
||||
Endpoint = public-server1.example-vpn.tld:51820
|
||||
PublicKey = <public key for public-server1.example-vpn.tld>
|
||||
# routes traffic to itself and entire subnet of peers as bounce server
|
||||
AllowedIPs = 10.0.0.1/24
|
||||
PersistentKeepalive = 25
|
Reference in New Issue
Block a user