mirror of
https://github.com/kernelkit/infix.git
synced 2026-08-01 21:33:02 +02:00
confd: add support for host containers, shares host's interfaces
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
@@ -69,6 +69,9 @@ static int add(const char *name, struct lyd_node *cif)
|
||||
}
|
||||
}
|
||||
|
||||
if (lydx_is_enabled(cif, "host-network"))
|
||||
fprintf(fp, " host");
|
||||
|
||||
fprintf(fp, "\n");
|
||||
fchmod(fileno(fp), 0700);
|
||||
fclose(fp);
|
||||
|
||||
@@ -87,15 +87,16 @@ module infix-containers {
|
||||
choice network {
|
||||
description "Select network mode: none, host, or container network interfaces.";
|
||||
|
||||
case host {
|
||||
case host-network {
|
||||
leaf host {
|
||||
description "Run as host container, with full access to all network interfaces.";
|
||||
description "Run in same network namespace as host.";
|
||||
type boolean;
|
||||
}
|
||||
}
|
||||
|
||||
case network {
|
||||
list network {
|
||||
description "Container network interface to connect to the container.";
|
||||
key name;
|
||||
|
||||
leaf name {
|
||||
|
||||
Reference in New Issue
Block a user