Skip to content

Commit 9c0ce5f

Browse files
authoredJul 17, 2024··
Merge pull request #827 from flavio/fix-policies-yml-parsing
fix policies yml parsing
2 parents 1677586 + c2297bf commit 9c0ce5f

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed
 

‎policies.yml.example

+3-3
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,22 @@ psp-capabilities:
88
required_drop_capabilities: ["KILL"]
99
pod-image-signatures: # policy group
1010
policies:
11-
- name: sigstore_pgp
11+
sigstore_pgp:
1212
url: ghcr.io/kubewarden/policies/verify-image-signatures:v0.2.8
1313
settings:
1414
signatures:
1515
- image: "*"
1616
pubKeys:
1717
- "-----BEGIN PUBLIC KEY-----xxxxx-----END PUBLIC KEY-----"
1818
- "-----BEGIN PUBLIC KEY-----xxxxx-----END PUBLIC KEY-----"
19-
- name: sigstore_gh_action
19+
sigstore_gh_action:
2020
url: ghcr.io/kubewarden/policies/verify-image-signatures:v0.2.8
2121
settings:
2222
signatures:
2323
- image: "*"
2424
githubActions:
2525
owner: "kubewarden"
26-
- name: reject_latest_tag
26+
reject_latest_tag:
2727
url: ghcr.io/kubewarden/policies/trusted-repos-policy:v0.1.12
2828
settings:
2929
tags:

‎src/config.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ impl PolicyGroupMember {
333333

334334
/// Describes a policy that can be either an individual policy or a group policy.
335335
#[derive(Deserialize, Debug, Clone)]
336-
#[serde(deny_unknown_fields, untagged, rename_all = "camelCase")]
336+
#[serde(untagged, rename_all = "camelCase")]
337337
pub enum PolicyOrPolicyGroup {
338338
/// An individual policy
339339
Policy {

0 commit comments

Comments
 (0)
Please sign in to comment.