summaryrefslogtreecommitdiffstats
path: root/molecule
diff options
context:
space:
mode:
authorAhmed AbdelHalim <[email protected]>2025-08-20 23:37:21 +0200
committerAhmed AbdelHalim <[email protected]>2025-08-21 00:46:50 +0200
commitb8be9cf4e3203490f73835c04c9b97814a61a3d6 (patch)
tree96bb58b08b54997669e6a9c415a53a7f4d1bd277 /molecule
parent5e80f0bc555ffbe7203d0ab7dac0e759e0f3a217 (diff)
Add wireguard role and fix testing
The testing was failing because the use of the example files with the same domain names, resulted in the files and the molecule variable were being merged and therefore running tasks that would fail on test (example, setting a fake VPN connection that wouldn't start).
Diffstat (limited to 'molecule')
-rw-r--r--molecule/default/converge.yml31
1 files changed, 21 insertions, 10 deletions
diff --git a/molecule/default/converge.yml b/molecule/default/converge.yml
index b83ecfe6..300360d4 100644
--- a/molecule/default/converge.yml
+++ b/molecule/default/converge.yml
@@ -15,19 +15,30 @@
python_global_version: "3.13"
python_versions:
- "3.13"
- - "3.12"
pihole_interface: "eth0"
pihole_domain: "pi.hole"
+ wireguard_connections:
+ protonvpn-example: |
+ [Interface]
+ PrivateKey = your_private_key_here
+ Address = 10.2.0.2/32
+ DNS = 10.2.0.1
+
+ [Peer]
+ PublicKey = server_public_key
+ AllowedIPs = 0.0.0.0/0
+ Endpoint = example.protonvpn.com:51820
roles:
- - role: network
- - role: user
- - role: ssh
- - role: password_policy
- - role: locales
- - role: timezone
- - role: homebrew
- - role: python
- - role: pihole
+ - role: "network"
+ - role: "user"
+ - role: "ssh"
+ - role: "password_policy"
+ - role: "locales"
+ - role: "timezone"
+ - role: "homebrew"
+ - role: "python"
+ - role: "wireguard"
+ - role: "pihole"
when:
- lookup('ansible.builtin.env', 'MOLECULE_DISTRO') == 'ubuntu' or
lookup('ansible.builtin.env', 'MOLECULE_DISTRO') == 'raspberrypi'