summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2021-01-06 12:12:39 +0100
committerTrygve Laugstøl <trygvis@inamo.no>2021-01-06 12:12:39 +0100
commitb40cab15f4d01a4e8455e5808ca82e40ff291a92 (patch)
tree91ca5f2c2cd812776662d58de12a094b8278093b
parentb8699860653e593271e50c8ba1b73f66fcb6287c (diff)
downloadrules-sandbox-b40cab15f4d01a4e8455e5808ca82e40ff291a92.tar.gz
rules-sandbox-b40cab15f4d01a4e8455e5808ca82e40ff291a92.tar.bz2
rules-sandbox-b40cab15f4d01a4e8455e5808ca82e40ff291a92.tar.xz
rules-sandbox-b40cab15f4d01a4e8455e5808ca82e40ff291a92.zip
Renaming VPN stuff to wireguard.
-rw-r--r--acme.yaml2
-rw-r--r--module/ri-engine/src/main/java/io/trygvis/rules/network/IpCalc.java (renamed from module/ri-engine/src/main/java/io/trygvis/rules/acme/IpCalc.java)18
-rw-r--r--module/ri-engine/src/main/resources/io/trygvis/rules/acme/acme.drl10
-rw-r--r--module/ri-engine/src/test/java/io/trygvis/rules/network/IpCalcTest.java (renamed from module/ri-engine/src/test/java/io/trygvis/rules/acme/IpCalcTest.java)8
-rw-r--r--module/ri-wireguard/src/main/java/io/trygvis/rules/acme/Foo.java7
-rw-r--r--module/ri-wireguard/src/main/resources/META-INF/kmodule.xml2
-rw-r--r--module/ri-wireguard/src/main/resources/io/trygvis/rules/wireguard/wireguard.drl (renamed from module/ri-wireguard/src/main/resources/io/trygvis/rules/acme/vpn.drl)6
-rw-r--r--out/phase-1.yaml382
-rw-r--r--out/vpn0.yaml190
9 files changed, 299 insertions, 326 deletions
diff --git a/acme.yaml b/acme.yaml
index 818422a..24c07cb 100644
--- a/acme.yaml
+++ b/acme.yaml
@@ -35,7 +35,7 @@ data:
name: ws-2
--- # Wireguard VPN network
-type: io.trygvis.rules.acme.WgNet
+type: io.trygvis.rules.wireguard.WgNet
data:
name: vpn0
domain: vpn.acme.com
diff --git a/module/ri-engine/src/main/java/io/trygvis/rules/acme/IpCalc.java b/module/ri-engine/src/main/java/io/trygvis/rules/network/IpCalc.java
index 5369d62..e40e169 100644
--- a/module/ri-engine/src/main/java/io/trygvis/rules/acme/IpCalc.java
+++ b/module/ri-engine/src/main/java/io/trygvis/rules/network/IpCalc.java
@@ -1,26 +1,10 @@
-package io.trygvis.rules.acme;
+package io.trygvis.rules.network;
-import io.trygvis.rules.network.Ipv4Cidr;
-
-import java.net.InetAddress;
-import java.net.UnknownHostException;
-import java.util.ArrayList;
-import java.util.List;
import java.util.regex.Pattern;
public class IpCalc {
private static final Pattern pattern = Pattern.compile("([0-9]{1,3})\\.([0-9]{1,3})\\.([0-9]{1,3})\\.([0-9]{1,3})/([0-9]{1,3})");
- public static class FirstLast {
- public final int first;
- public final int last;
-
- public FirstLast(int first, int last) {
- this.first = first;
- this.last = last;
- }
- }
-
public static Ipv4Cidr cidr(String cidr) {
var matcher = pattern.matcher(cidr);
if (!matcher.matches()) {
diff --git a/module/ri-engine/src/main/resources/io/trygvis/rules/acme/acme.drl b/module/ri-engine/src/main/resources/io/trygvis/rules/acme/acme.drl
index 0465343..7d53763 100644
--- a/module/ri-engine/src/main/resources/io/trygvis/rules/acme/acme.drl
+++ b/module/ri-engine/src/main/resources/io/trygvis/rules/acme/acme.drl
@@ -4,16 +4,13 @@ import io.trygvis.rules.machine.Machine;
import io.trygvis.rules.dba.Cluster;
import io.trygvis.rules.dba.Container;
+dialect "mvel"
+
declare AcmeServer
name : String
machine : Machine
end
-//declare MachinePublicName
-// machine : Machine
-// fqdn : String
-//end
-
rule "Ops"
when
$ops: AcmeOps()
@@ -56,7 +53,6 @@ when
$m : Machine(fqdn == null)
$s : AcmeServer(machine == $m)
then
- var fqdn = "%s.machine.acme.com".formatted($s.machine.name);
- $s.machine.fqdn = fqdn;
+ $s.machine.fqdn = "%s.machine.acme.com".formatted($s.machine.name);
update($s.machine)
end
diff --git a/module/ri-engine/src/test/java/io/trygvis/rules/acme/IpCalcTest.java b/module/ri-engine/src/test/java/io/trygvis/rules/network/IpCalcTest.java
index 8b1e2c6..e0642d6 100644
--- a/module/ri-engine/src/test/java/io/trygvis/rules/acme/IpCalcTest.java
+++ b/module/ri-engine/src/test/java/io/trygvis/rules/network/IpCalcTest.java
@@ -1,17 +1,17 @@
-package io.trygvis.rules.acme;
+package io.trygvis.rules.network;
-import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;
-import static org.junit.jupiter.api.Assertions.*;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertThrows;
class IpCalcTest {
@Test
public void basic() {
- Assertions.assertThrows(IllegalArgumentException.class, () -> IpCalc.cidr("192.168.1.1/24").addresses());
+ assertThrows(IllegalArgumentException.class, () -> IpCalc.cidr("192.168.1.1/24").addresses());
assertEquals(256, IpCalc.cidr("192.168.1.0/24").addresses().size());
assertEquals(128, IpCalc.cidr("192.168.1.128/25").addresses().size());
}
diff --git a/module/ri-wireguard/src/main/java/io/trygvis/rules/acme/Foo.java b/module/ri-wireguard/src/main/java/io/trygvis/rules/acme/Foo.java
deleted file mode 100644
index 44f5eba..0000000
--- a/module/ri-wireguard/src/main/java/io/trygvis/rules/acme/Foo.java
+++ /dev/null
@@ -1,7 +0,0 @@
-package io.trygvis.rules.acme;
-
-public class Foo {
- public static void main(String[] args) {
- System.out.println("Foo.main");
- }
-}
diff --git a/module/ri-wireguard/src/main/resources/META-INF/kmodule.xml b/module/ri-wireguard/src/main/resources/META-INF/kmodule.xml
index 64cc4d2..f046259 100644
--- a/module/ri-wireguard/src/main/resources/META-INF/kmodule.xml
+++ b/module/ri-wireguard/src/main/resources/META-INF/kmodule.xml
@@ -3,7 +3,7 @@
xmlns="http://www.drools.org/xsd/kmodule"
xsi:schemaLocation="http://www.drools.org/xsd/kmodule https://www.drools.org/xsd/kmodule_7_1.xsd">
- <kbase name="wireguard" packages="io.trygvis.rules.acme">
+ <kbase name="wireguard" packages="io.trygvis.rules.wireguard">
<ksession name="wireguard"/>
</kbase>
</kmodule>
diff --git a/module/ri-wireguard/src/main/resources/io/trygvis/rules/acme/vpn.drl b/module/ri-wireguard/src/main/resources/io/trygvis/rules/wireguard/wireguard.drl
index 7896953..342cbb5 100644
--- a/module/ri-wireguard/src/main/resources/io/trygvis/rules/acme/vpn.drl
+++ b/module/ri-wireguard/src/main/resources/io/trygvis/rules/wireguard/wireguard.drl
@@ -1,11 +1,11 @@
-package io.trygvis.rules.acme;
+package io.trygvis.rules.wireguard;
import java.util.ArrayList
-import io.trygvis.rules.machine.Machine;
import io.trygvis.rules.dns.DnsEntry;
-import io.trygvis.rules.acme.AcmeServer
+import io.trygvis.rules.machine.Machine;
import io.trygvis.rules.network.Ipv4Address
import io.trygvis.rules.network.Ipv4Cidr
+import io.trygvis.rules.network.IpCalc
dialect "mvel"
diff --git a/out/phase-1.yaml b/out/phase-1.yaml
index c0d093a..9ebaa02 100644
--- a/out/phase-1.yaml
+++ b/out/phase-1.yaml
@@ -30,197 +30,6 @@ data:
name: "acme-3"
fqdn: "acme-3.machine.acme.com"
---
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "acme-1"
- to: "acme-2"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "acme-1"
- to: "acme-3"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "acme-2"
- to: "acme-1"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "acme-2"
- to: "acme-3"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "acme-3"
- to: "acme-1"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "acme-3"
- to: "acme-2"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "ws-1"
- to: "acme-1"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "ws-1"
- to: "acme-2"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "ws-1"
- to: "acme-3"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "ws-2"
- to: "acme-1"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "ws-2"
- to: "acme-2"
----
-type: "io.trygvis.rules.acme.WgConnection"
-data:
- host: "ws-2"
- to: "acme-3"
----
-type: "io.trygvis.rules.acme.WgHost"
-data:
- name: "acme-1"
- net: "vpn0"
- publicName: "acme-1.machine.acme.com"
- netToNetIp: null
- networkIp: null
----
-type: "io.trygvis.rules.acme.WgHost"
-data:
- name: "acme-2"
- net: "vpn0"
- publicName: "acme-2.machine.acme.com"
- netToNetIp: null
- networkIp: null
----
-type: "io.trygvis.rules.acme.WgHost"
-data:
- name: "acme-3"
- net: "vpn0"
- publicName: "acme-3.machine.acme.com"
- netToNetIp: null
- networkIp: null
----
-type: "io.trygvis.rules.acme.WgHost"
-data:
- name: "ws-1"
- net: "vpn0"
- publicName: null
- netToNetIp: null
- networkIp: null
----
-type: "io.trygvis.rules.acme.WgHost"
-data:
- name: "ws-2"
- net: "vpn0"
- publicName: null
- netToNetIp: null
- networkIp: null
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "acme-1"
- role: "link"
- ip:
- value: "192.168.10.4"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "acme-1"
- role: "network"
- ip:
- value: "10.55.55.4"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "acme-2"
- role: "link"
- ip:
- value: "192.168.10.3"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "acme-2"
- role: "network"
- ip:
- value: "10.55.55.3"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "acme-3"
- role: "link"
- ip:
- value: "192.168.10.2"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "acme-3"
- role: "network"
- ip:
- value: "10.55.55.2"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "ws-1"
- role: "link"
- ip:
- value: "192.168.10.1"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "ws-1"
- role: "network"
- ip:
- value: "10.55.55.1"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "ws-2"
- role: "link"
- ip:
- value: "192.168.10.0"
----
-type: "io.trygvis.rules.acme.WgIpAllocation"
-data:
- host: "ws-2"
- role: "network"
- ip:
- value: "10.55.55.0"
----
-type: "io.trygvis.rules.acme.WgIpPool"
-data:
- net: "vpn0"
- role: "link"
- cidr:
- value: "192.168.10.0/29"
----
-type: "io.trygvis.rules.acme.WgIpPool"
-data:
- net: "vpn0"
- role: "network"
- cidr:
- value: "10.55.55.0/24"
----
-type: "io.trygvis.rules.acme.WgNet"
-data:
- name: "vpn0"
- domain: "vpn.acme.com"
- linkCidr: "192.168.10.0/29"
- networkCidr: "10.55.55.0/24"
----
type: "io.trygvis.rules.dba.Cluster"
data:
name: "acme-ci"
@@ -486,3 +295,194 @@ data:
name: "ws-2"
fqdn: null
key: "ws-2"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "acme-1"
+ to: "acme-2"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "acme-1"
+ to: "acme-3"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "acme-2"
+ to: "acme-1"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "acme-2"
+ to: "acme-3"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "acme-3"
+ to: "acme-1"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "acme-3"
+ to: "acme-2"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "ws-1"
+ to: "acme-1"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "ws-1"
+ to: "acme-2"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "ws-1"
+ to: "acme-3"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "ws-2"
+ to: "acme-1"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "ws-2"
+ to: "acme-2"
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
+data:
+ host: "ws-2"
+ to: "acme-3"
+---
+type: "io.trygvis.rules.wireguard.WgHost"
+data:
+ name: "acme-1"
+ net: "vpn0"
+ publicName: "acme-1.machine.acme.com"
+ netToNetIp: null
+ networkIp: null
+---
+type: "io.trygvis.rules.wireguard.WgHost"
+data:
+ name: "acme-2"
+ net: "vpn0"
+ publicName: "acme-2.machine.acme.com"
+ netToNetIp: null
+ networkIp: null
+---
+type: "io.trygvis.rules.wireguard.WgHost"
+data:
+ name: "acme-3"
+ net: "vpn0"
+ publicName: "acme-3.machine.acme.com"
+ netToNetIp: null
+ networkIp: null
+---
+type: "io.trygvis.rules.wireguard.WgHost"
+data:
+ name: "ws-1"
+ net: "vpn0"
+ publicName: null
+ netToNetIp: null
+ networkIp: null
+---
+type: "io.trygvis.rules.wireguard.WgHost"
+data:
+ name: "ws-2"
+ net: "vpn0"
+ publicName: null
+ netToNetIp: null
+ networkIp: null
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "acme-1"
+ role: "link"
+ ip:
+ value: "192.168.10.4"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "acme-1"
+ role: "network"
+ ip:
+ value: "10.55.55.4"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "acme-2"
+ role: "link"
+ ip:
+ value: "192.168.10.3"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "acme-2"
+ role: "network"
+ ip:
+ value: "10.55.55.3"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "acme-3"
+ role: "link"
+ ip:
+ value: "192.168.10.2"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "acme-3"
+ role: "network"
+ ip:
+ value: "10.55.55.2"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "ws-1"
+ role: "link"
+ ip:
+ value: "192.168.10.1"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "ws-1"
+ role: "network"
+ ip:
+ value: "10.55.55.1"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "ws-2"
+ role: "link"
+ ip:
+ value: "192.168.10.0"
+---
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
+data:
+ host: "ws-2"
+ role: "network"
+ ip:
+ value: "10.55.55.0"
+---
+type: "io.trygvis.rules.wireguard.WgIpPool"
+data:
+ net: "vpn0"
+ role: "link"
+ cidr:
+ value: "192.168.10.0/29"
+---
+type: "io.trygvis.rules.wireguard.WgIpPool"
+data:
+ net: "vpn0"
+ role: "network"
+ cidr:
+ value: "10.55.55.0/24"
+---
+type: "io.trygvis.rules.wireguard.WgNet"
+data:
+ name: "vpn0"
+ domain: "vpn.acme.com"
+ linkCidr: "192.168.10.0/29"
+ networkCidr: "10.55.55.0/24"
diff --git a/out/vpn0.yaml b/out/vpn0.yaml
index fb8c684..4601931 100644
--- a/out/vpn0.yaml
+++ b/out/vpn0.yaml
@@ -1,65 +1,130 @@
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "acme-1.machine.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "acme-1.vpn.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "acme-2.machine.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "acme-2.vpn.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "acme-3.machine.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "acme-3.vpn.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "ws-1.vpn.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.dns.DnsEntry"
+data:
+ fqdn: "ws-2.vpn.acme.com"
+ type: "A"
+---
+type: "io.trygvis.rules.machine.Machine"
+data:
+ name: "acme-1"
+ fqdn: "acme-1.machine.acme.com"
+---
+type: "io.trygvis.rules.machine.Machine"
+data:
+ name: "acme-2"
+ fqdn: "acme-2.machine.acme.com"
+---
+type: "io.trygvis.rules.machine.Machine"
+data:
+ name: "acme-3"
+ fqdn: "acme-3.machine.acme.com"
+---
+type: "io.trygvis.rules.machine.Machine"
+data:
+ name: "ws-1"
+ fqdn: null
+---
+type: "io.trygvis.rules.machine.Machine"
+data:
+ name: "ws-2"
+ fqdn: null
+---
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "acme-1"
to: "acme-2"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "acme-1"
to: "acme-3"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "acme-2"
to: "acme-1"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "acme-2"
to: "acme-3"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "acme-3"
to: "acme-1"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "acme-3"
to: "acme-2"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "ws-1"
to: "acme-1"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "ws-1"
to: "acme-2"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "ws-1"
to: "acme-3"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "ws-2"
to: "acme-1"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "ws-2"
to: "acme-2"
---
-type: "io.trygvis.rules.acme.WgConnection"
+type: "io.trygvis.rules.wireguard.WgConnection"
data:
host: "ws-2"
to: "acme-3"
---
-type: "io.trygvis.rules.acme.WgHost"
+type: "io.trygvis.rules.wireguard.WgHost"
data:
name: "acme-1"
net: "vpn0"
@@ -67,7 +132,7 @@ data:
netToNetIp: null
networkIp: null
---
-type: "io.trygvis.rules.acme.WgHost"
+type: "io.trygvis.rules.wireguard.WgHost"
data:
name: "acme-2"
net: "vpn0"
@@ -75,7 +140,7 @@ data:
netToNetIp: null
networkIp: null
---
-type: "io.trygvis.rules.acme.WgHost"
+type: "io.trygvis.rules.wireguard.WgHost"
data:
name: "acme-3"
net: "vpn0"
@@ -83,7 +148,7 @@ data:
netToNetIp: null
networkIp: null
---
-type: "io.trygvis.rules.acme.WgHost"
+type: "io.trygvis.rules.wireguard.WgHost"
data:
name: "ws-1"
net: "vpn0"
@@ -91,7 +156,7 @@ data:
netToNetIp: null
networkIp: null
---
-type: "io.trygvis.rules.acme.WgHost"
+type: "io.trygvis.rules.wireguard.WgHost"
data:
name: "ws-2"
net: "vpn0"
@@ -99,158 +164,93 @@ data:
netToNetIp: null
networkIp: null
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "acme-1"
role: "link"
ip:
value: "192.168.10.4"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "acme-1"
role: "network"
ip:
value: "10.55.55.4"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "acme-2"
role: "link"
ip:
value: "192.168.10.3"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "acme-2"
role: "network"
ip:
value: "10.55.55.3"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "acme-3"
role: "link"
ip:
value: "192.168.10.2"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "acme-3"
role: "network"
ip:
value: "10.55.55.2"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "ws-1"
role: "link"
ip:
value: "192.168.10.1"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "ws-1"
role: "network"
ip:
value: "10.55.55.1"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "ws-2"
role: "link"
ip:
value: "192.168.10.0"
---
-type: "io.trygvis.rules.acme.WgIpAllocation"
+type: "io.trygvis.rules.wireguard.WgIpAllocation"
data:
host: "ws-2"
role: "network"
ip:
value: "10.55.55.0"
---
-type: "io.trygvis.rules.acme.WgIpPool"
+type: "io.trygvis.rules.wireguard.WgIpPool"
data:
net: "vpn0"
role: "link"
cidr:
value: "192.168.10.0/29"
---
-type: "io.trygvis.rules.acme.WgIpPool"
+type: "io.trygvis.rules.wireguard.WgIpPool"
data:
net: "vpn0"
role: "network"
cidr:
value: "10.55.55.0/24"
---
-type: "io.trygvis.rules.acme.WgNet"
+type: "io.trygvis.rules.wireguard.WgNet"
data:
name: "vpn0"
domain: "vpn.acme.com"
linkCidr: "192.168.10.0/29"
networkCidr: "10.55.55.0/24"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "acme-1.machine.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "acme-1.vpn.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "acme-2.machine.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "acme-2.vpn.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "acme-3.machine.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "acme-3.vpn.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "ws-1.vpn.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.dns.DnsEntry"
-data:
- fqdn: "ws-2.vpn.acme.com"
- type: "A"
----
-type: "io.trygvis.rules.machine.Machine"
-data:
- name: "acme-1"
- fqdn: "acme-1.machine.acme.com"
----
-type: "io.trygvis.rules.machine.Machine"
-data:
- name: "acme-2"
- fqdn: "acme-2.machine.acme.com"
----
-type: "io.trygvis.rules.machine.Machine"
-data:
- name: "acme-3"
- fqdn: "acme-3.machine.acme.com"
----
-type: "io.trygvis.rules.machine.Machine"
-data:
- name: "ws-1"
- fqdn: null
----
-type: "io.trygvis.rules.machine.Machine"
-data:
- name: "ws-2"
- fqdn: null