Skip to content

Commit

Permalink
add networkpolicy for kserve namespace
Browse files Browse the repository at this point in the history
Signed-off-by: Jooho Lee <[email protected]>
  • Loading branch information
Jooho committed Feb 27, 2025
1 parent 9b9b9ff commit e688834
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions test/scripts/openshift-ci/setup-e2e-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -172,4 +172,24 @@ kustomize build $PROJECT_ROOT/config/overlays/test/clusterresources |
# no effect, because of missing Knative
oc annotate servingruntimes -n kserve-ci-e2e-test --all serving.knative.openshift.io/enablePassthrough=true


# Allow all traffic to the kserve namespace. Without this networkpolicy, webhook will return 500
# error msg: 'http: server gave HTTP response to HTTPS client"}]},"code":500}'
cat <<EOF | oc apply -f -
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-all
namespace: kserve
spec:
podSelector: {}
ingress:
- {}
egress:
- {}
policyTypes:
- Ingress
- Egress
EOF

echo "Setup complete"

0 comments on commit e688834

Please sign in to comment.