Skip to content

Commit

Permalink
update allowAll condition (#32)
Browse files Browse the repository at this point in the history
Signed-off-by: Shubham Chaudhary <[email protected]>
  • Loading branch information
ispeakc0de committed Aug 21, 2024
1 parent 6c554dd commit 9b1f003
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion internal/pods/pods.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func validateCreate(clients clients.ClientSets) hook.AdmitFunc {
if !allowed {
return &hook.Result{
Allowed: false,
Msg: fmt.Sprintf("origin image doesn't met allowed image criteria: %v", msg),
Msg: fmt.Sprintf("origin image doesn't met allowed image criteria %v", msg),
}, nil
}

Expand Down
2 changes: 1 addition & 1 deletion internal/pods/restrict.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ func validateOriginPodImage(namespace string, extras map[string]v1.ExtraValue, c

func originFromTerminal(serviceAccount string) bool {
if utils.WebHookFilters.AllowedOriginServiceAccount.AllowedAll {
return true
return false
}
if strings.Contains(serviceAccount, "system:serviceaccount") {
return false
Expand Down

0 comments on commit 9b1f003

Please sign in to comment.