File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1152,11 +1152,24 @@ This setting can be enabled on at most one cluster per incus host.
11521152**default value**: true
11531153
11541154By default, the LXC containers created by Magic Castle are privileged. It is possible for security reasons
1155- to turn this off by provider `privileged = false` to the Incus module. However, due to kernel restrictions
1155+ to turn this off by provider `privileged = false` to the Incus module. However, due to kernel restrictions
11561156designed to prevent unprivileged users from performing privileged operations like initiating mounts,
11571157the following features have to be disabled when running with `privileged = false`:
11581158- NFS server and mounts (`profile::nfs`)
11591159
1160+ Also make sure that the line `root:1000000:1000000000` exists in both
1161+ `/etc/subuid` and `/etc/subgid` when running with `privileged = false`.
1162+
1163+ **Post build modification effect**: rebuild of all instances at next `terraform apply`.
1164+
1165+ ### nesting (optional)
1166+
1167+ **default value**: true
1168+
1169+ By default, the LXC containers created by Magic Castle have nesting enabled.
1170+ This allows containers to run workloads that require features such as docker or systemd inside the container.
1171+ It is possible, for security or isolation reasons, to disable this by setting `nesting = false` in the Incus module.
1172+
11601173**Post build modification effect**: rebuild of all instances at next `terraform apply`.
11611174
11621175### shared_filesystems (optional)
Original file line number Diff line number Diff line change @@ -13,6 +13,11 @@ variable "privileged" {
1313 default = true
1414}
1515
16+ variable "nesting" {
17+ description = " When using container, set the config security.nesting to this value"
18+ default = true
19+ }
20+
1621variable "shared_filesystems" {
1722 description = " Name of filesystems that need to be created and mounted in every instance"
1823 default = []
Original file line number Diff line number Diff line change @@ -93,7 +93,7 @@ resource "incus_instance" "instances" {
9393 config = {
9494 " cloud-init.user-data" = module.configuration.user_data[each.key]
9595 " security.privileged" = var.privileged
96- " security.nesting" = var.privileged
96+ " security.nesting" = var.nesting
9797 }
9898
9999 device {
You can’t perform that action at this time.
0 commit comments