-
Notifications
You must be signed in to change notification settings - Fork 709
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix e2e manual remediation for resource quota
This is to fix the e2e failures of resource_requests_quota_per_project caused by manual remediation of antoher rule/
- Loading branch information
1 parent
3d06a8e
commit f7c7d3b
Showing
2 changed files
with
36 additions
and
1 deletion.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
...tions/openshift/general/resource_requests_quota_per_project/tests/ocp4/e2e-remediation.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#!/bin/bash | ||
|
||
|
||
|
||
# Deploy a resource quota for e2e-test namespace, this namespace is created by the e2e-remediation.sh script | ||
# under the applications/openshift/networking/configure_network_policies_namespaces/tests/ocp4/e2e-remediation.sh | ||
# let's create a new project anyway because this could run before the other script | ||
cat << EOF | oc apply -f - | ||
--- | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
name: e2e-test | ||
EOF | ||
|
||
cat << EOF | oc apply -n e2e-test -f - | ||
--- | ||
apiVersion: v1 | ||
kind: ResourceQuota | ||
metadata: | ||
name: e2e-test-namespace-quotas | ||
spec: | ||
hard: | ||
count/daemonsets.apps: "0" | ||
count/deployments.apps: "0" | ||
limits.cpu: "0" | ||
limits.memory: "0" | ||
pods: "0" | ||
EOF |
8 changes: 7 additions & 1 deletion
8
.../openshift/networking/configure_network_policies_namespaces/tests/ocp4/e2e-remediation.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters