-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathclipboard.txt
73 lines (54 loc) · 1.72 KB
/
clipboard.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
##Clipboard for setup
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
###local
network ip:
pi internal ip:
device ip:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
###aws
aws instance name:
aws public ip:
aws security group:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
###wireguard keys
pi private key:
pi public key:
ec2 private key:
ec2 public key:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
###ZemiSmart IDs
Access ID:
Access Secret:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
###pi wg config
# local settings for pi
[Interface]
PrivateKey = <pi private key>
Address = 10.0.3.2/32
ListenPort = 51833
# IP forwarding
PreUp = sysctl -w net.ipv4.ip_forward=1
# IP masquerading
PreUp = iptables -t mangle -A PREROUTING -i HA-tunnel -j MARK --set-mark 0x31
PreUp = iptables -t nat -A POSTROUTING ! -o HA-tunnel -m mark --mark 0x31 -j MASQUERADE
PostDown = iptables -t mangle -D PREROUTING -i HA-tunnel -j MARK --set-mark 0x31
PostDown = iptables -t nat -D POSTROUTING ! -o HA-tunnel -m mark --mark 0x31 -j MASQUERADE
PostUp = iptables -A FORWARD -i %i -j ACCEPT; iptables -A FORWARD -o %i -j ACCEPT; iptables -t nat -A POSTROUTING -o enp2s0 -j MASQUERADE
PostDown = iptables -D FORWARD -i %i -j ACCEPT; iptables -D FORWARD -o %i -j ACCEPT; iptables -t nat -D POSTROUTING -o enp2s0 -j MASQUERADE
# remote settings for ec2
[Peer]
PublicKey = <ec2 public key>
AllowedIPs = 10.0.3.1/32
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
###aws wg config
# local settings for Endpoint A
[Interface]
PrivateKey = <ec2 private key>
Address = 10.0.3.1/32
ListenPort = 51834
# remote settings for Host β
[Peer]
PublicKey = <pi public key>
Endpoint = <network ip>:51833
AllowedIPs = <pi ip>/32
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~