forked from Deuxfleurs/diplonat
WIP consul
This commit is contained in:
parent
4cce225043
commit
fe1d91fe06
3 changed files with 24 additions and 0 deletions
|
@ -7,6 +7,14 @@ Diplonat
|
||||||
* [ ] (Re)Configure nftable (prio: low)
|
* [ ] (Re)Configure nftable (prio: low)
|
||||||
* [ ] (Re)Configure DNS via ??? (prio: low)
|
* [ ] (Re)Configure DNS via ??? (prio: low)
|
||||||
|
|
||||||
|
## Understand scope
|
||||||
|
|
||||||
|
* Reconfigure __local__ environment when provisionning a __cluster__ service
|
||||||
|
* Reconfigure host on demand according to service needs (Firewall)
|
||||||
|
* Reconfigure host local network according to service needs (Router NAT)
|
||||||
|
* Operate a global reconfiguration that associate the tuple (__local__ environment information, a __cluster__ service)
|
||||||
|
* Reconfigure an external service with local info (DNS with public IP returned by the router via IGD)
|
||||||
|
|
||||||
## Operate
|
## Operate
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|
15
src/consul_actor.rs
Normal file
15
src/consul_actor.rs
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
use crate::consul::Consul;
|
||||||
|
use tokio::sync::watch;
|
||||||
|
|
||||||
|
pub struct ConsulActor {
|
||||||
|
consul: Consul
|
||||||
|
out:
|
||||||
|
}
|
||||||
|
|
||||||
|
impl ConsulActor {
|
||||||
|
fn new(url: &str) -> Self {
|
||||||
|
return Self {
|
||||||
|
consul: Consul::new(url);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,4 +1,5 @@
|
||||||
mod consul;
|
mod consul;
|
||||||
|
mod consul_actor;
|
||||||
|
|
||||||
//use std::net::SocketAddrV4;
|
//use std::net::SocketAddrV4;
|
||||||
//use std::collections::HashMap;
|
//use std::collections::HashMap;
|
||||||
|
|
Loading…
Reference in a new issue