Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion internal/ironic/initcontainer.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,6 @@ func InitContainer(init APIDetails) []corev1.Container {
Capabilities: &corev1.Capabilities{
Drop: []corev1.Capability{"ALL"},
Add: []corev1.Capability{
"CHOWN",
"DAC_OVERRIDE",
"FOWNER",
"SYS_ADMIN",
Expand Down
4 changes: 0 additions & 4 deletions internal/ironicconductor/statefulset.go
Original file line number Diff line number Diff line change
Expand Up @@ -226,13 +226,9 @@ func StatefulSet(
RunAsNonRoot: ptr.To(false),
Capabilities: &corev1.Capabilities{
Drop: []corev1.Capability{"ALL"},
// With ALL dropped, root grants nothing on its own --
// each capability dnsmasq uses must be listed:
Add: []corev1.Capability{
"NET_BIND_SERVICE", // bind TFTP 69 / DHCP 67,547 (<1024)
"NET_ADMIN",
"NET_RAW",
"SETGID", // drop to the unprivileged dnsmasq group
},
},
},
Expand Down
7 changes: 1 addition & 6 deletions internal/ironicinspector/statefulset.go
Original file line number Diff line number Diff line change
Expand Up @@ -274,13 +274,8 @@ func StatefulSet(
RunAsNonRoot: ptr.To(false),
Capabilities: &corev1.Capabilities{
Drop: []corev1.Capability{"ALL"},
// With ALL dropped, root grants nothing on its own --
// each capability dnsmasq uses must be listed:
Add: []corev1.Capability{
"NET_BIND_SERVICE", // bind TFTP 69 / DHCP 67,547 (<1024)
"NET_ADMIN",
"NET_RAW",
"SETGID", // drop to the unprivileged dnsmasq group
"NET_ADMIN", "NET_RAW",
},
},
},
Expand Down
5 changes: 1 addition & 4 deletions templates/common/bin/pxe-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,7 @@ if [ -f "/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem" ] && [ -f "/var/lib/

# Copy the CA certificates
cp /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem /initramfs/etc/pki/ca-trust/source/anchors/
# chroot directly as real root; `unshare -r`'s single-uid userns breaks
# update-ca-trust's symlink creation because it cannot access files
# owned by another user
chroot ./initramfs /bin/sh -c "update-ca-trust"
echo update-ca-trust | unshare -r chroot ./initramfs

# Repack the initramfs
pushd initramfs
Expand Down