Commit Graph

17 Commits

Author SHA1 Message Date
dadfbee083 Split the application into modules
Splitting into modules will help keep concerns separate,
at the cost of a slightly more verbose code.
2020-05-13 13:52:54 +02:00
bce8a0451a Move the bindAddress computation to config parsing 2020-05-13 13:52:54 +02:00
9fdab65237 Revert "Move the metadata parsing code to node.go"
This reverts commit ac6289b5bf95e8903ea90ddf807832a2358371b0.
2020-05-13 13:52:54 +02:00
b0bfeb1f8e Move the metadata parsing code to node.go 2020-05-13 13:52:54 +02:00
0e799d6074 Parse metadata outside of cluster.go
Move the calls for metadata decoding from the cluster
membership management loop to the main loop. This task
was not directly related to the cluster, and was adding
complexity, including the need for multierr structures.
2020-05-13 13:52:54 +02:00
366f906d5d Do not pass the config object to newCluster
Decouple the config structure from the cluster management and
stop passing the config object around.
2020-05-13 13:52:54 +02:00
97525f4b10 Stop using wireguard in cluster.go
The wireguard is mostly used to compute metadata.
Metadata is now computed by main.go and encoded in
node.go, the cluster only receives a function generating
the binary metadata.
2020-05-13 13:52:54 +02:00
709349d121 use structured logging 2020-01-31 19:36:18 +01:00
5427aa5e84 retry join instead of failing
this make it easier to bootstrap a cluster and also makes the cluster
more resilient to full-cluster failures or restarts

fixes #6
2019-08-06 21:53:38 +02:00
3a401a7942 try some cleanup if iface setup failed 2019-07-29 19:20:53 +02:00
f4e61df211 use wgctrl lib instead of wrapping wg-tools
fixes: #3
2019-07-12 11:08:14 +02:00
3559fcf3b3 also skip /etc/hosts on termination if disabled 2019-07-06 22:41:58 +02:00
c1a3cc33f4 also down iface on shutdown 2019-03-27 22:52:34 +01:00
407bfbfb7e add version flag 2019-03-26 23:32:36 +01:00
e89a7141e5 add hosts file support 2019-03-26 23:32:36 +01:00
b1ff41c523 simplify option names 2019-03-26 23:32:36 +01:00
5e01de00c1 first working PoC 2019-03-26 23:32:36 +01:00