Skip to content

Commit dacb45e

Browse files
authored
Merge pull request #468 from gkurz/static-image-signature-config
Enable image signature check for CoCo
2 parents d0632e5 + 1e86654 commit dacb45e

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

config/peerpods/podvm/lib.sh

+12
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,18 @@ function prepare_source_code() {
244244
fi
245245
fi
246246

247+
# Enable image signature check
248+
if [[ "$CONFIDENTIAL_COMPUTE_ENABLED" == "yes" ]]; then
249+
cat<<EOF>"${podvm_dir}"/files/etc/agent-config.toml
250+
server_addr = "unix:///run/kata-containers/agent.sock"
251+
guest_components_procs = "none"
252+
image_registry_auth = "file:///run/peerpod/auth.json"
253+
enable_signature_verification = true
254+
image_policy_file = "kbs:///default/security-policy/osc"
255+
EOF
256+
sed -i 's,/run/peerpod/agent-config.toml,/etc/agent-config.toml,' \
257+
"${podvm_dir}"/files/etc/systemd/system/kata-agent.service
258+
fi
247259
}
248260
249261
# Download and extract the pause container image

0 commit comments

Comments
 (0)