Skip to content

Commit

Permalink
Merge pull request #468 from gkurz/static-image-signature-config
Browse files Browse the repository at this point in the history
Enable image signature check for CoCo
  • Loading branch information
gkurz authored Oct 28, 2024
2 parents d0632e5 + 1e86654 commit dacb45e
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions config/peerpods/podvm/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,18 @@ function prepare_source_code() {
fi
fi

# Enable image signature check
if [[ "$CONFIDENTIAL_COMPUTE_ENABLED" == "yes" ]]; then
cat<<EOF>"${podvm_dir}"/files/etc/agent-config.toml
server_addr = "unix:///run/kata-containers/agent.sock"
guest_components_procs = "none"
image_registry_auth = "file:///run/peerpod/auth.json"
enable_signature_verification = true
image_policy_file = "kbs:///default/security-policy/osc"
EOF
sed -i 's,/run/peerpod/agent-config.toml,/etc/agent-config.toml,' \
"${podvm_dir}"/files/etc/systemd/system/kata-agent.service
fi
}
# Download and extract the pause container image
Expand Down

0 comments on commit dacb45e

Please sign in to comment.