Skip to content

Commit 23a99fe

Browse files
authored
Merge pull request #2 from hazelops/feature/initial
Add template for WireGuard GUI client to README.md
2 parents b7a87c7 + de3784e commit 23a99fe

File tree

1 file changed

+29
-3
lines changed

1 file changed

+29
-3
lines changed

README.md

+29-3
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,45 @@ Before using this module, you'll need to:
77

88
1. Install the [WireGuard tools](https://www.wireguard.com/install/) for your OS.
99

10-
2. Generate a key pair for each client:
10+
2. Generate a key pair for each client with a WireGuard tool:
1111
```bash
1212
wg genkey | tee client1-privatekey | wg pubkey > client1-publickey
1313
```
1414

15-
3. Generate a key pair for the server
15+
3. Generate a key pair for the server with a WireGuard tool:
1616
```bash
1717
wg genkey | tee server-privatekey | wg pubkey > server-publickey
1818
```
1919
4. Add each client's public key, along with the next available IP address to the `wg_clients` list.
2020

2121
5. Add server's private key to the `wg_server_private_key` variable. You can use AWS SSM Parameter store to store and read server private key.
22-
22+
5.1 To store the private key you could use this command:
23+
24+
```shell
25+
aws ssm put-parameter --name /wireguard/wg-server-private-key --type SecureString --value <Your Server Private Key>
26+
```
27+
28+
6. To create working configuration for the GUI WireGuard client, you should create a conf file from this template:
29+
30+
```toml
31+
[Interface]
32+
PrivateKey = <Your Client Private Key>
33+
ListenPort = 51820
34+
Address = 10.0.0.4/32 # Set your client's local ip address
35+
DNS = 8.8.8.8
36+
37+
[Peer]
38+
PublicKey = <Public Key of Your WireGuard Server>
39+
AllowedIPs = 10.0.0.0/24
40+
Endpoint = <IP or Domain Name of Your WireGuard Server>:51820
41+
PersistentKeepalive = 25
42+
```
43+
44+
Save this file as `<Your VPN Name>.conf`. Then you could import your configuration in WireGuard GUI client or share it with end users.
45+
46+
If you want to save or share more than one conf file - you can add them to single zip file without folders.
47+
48+
WireGuard GUI client support import of zipped configurations.
2349

2450
<!-- BEGINNING OF GENERATED BY TERRAFORM-DOCS -->
2551

0 commit comments

Comments
 (0)