-
Notifications
You must be signed in to change notification settings - Fork 384
OCPBUGS-61088: revert PR #2766 #2769
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
juzhao
wants to merge
12
commits into
openshift:main
Choose a base branch
from
juzhao:revert_2766
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
6aa4b10
Reapply "OCPBUGS-61088: revert PR #2738, enhance test for config_test…
juzhao 2ccdb99
update default-deny NP podSelector
juzhao 0c85699
update assertInClusterNetworkPolicyExists func to TestNetworkPolicy a…
juzhao e764f42
Merge branch 'main' into revert_2766
juzhao 757ab20
Update main_test.go
juzhao 2d1890a
rebase
juzhao e43aa2e
Revert "Update main_test.go"
juzhao d1c1b35
revert
juzhao b60ad95
Revert "revert"
juzhao ee45330
add TestNetworkPolicy func to main_test.go
juzhao e03a3ff
Revert "update assertInClusterNetworkPolicyExists func to TestNetwork…
juzhao 843e140
remove assertInClusterNetworkPolicyExists from test/e2e/config_test.go
juzhao File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,21 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: prometheus-operator-admission-webhook | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: https | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: prometheus-operator-admission-webhook | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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,25 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: alertmanager | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: tenancy | ||
| protocol: TCP | ||
| - port: web | ||
| protocol: TCP | ||
| - port: metrics | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: alertmanager | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
13 changes: 13 additions & 0 deletions
13
assets/cluster-monitoring-operator/network-policy-default-deny.yaml
This file contains hidden or 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,13 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: default-deny | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| podSelector: {} | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress | ||
This file contains hidden or 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,23 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: kube-state-metrics | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: https-main | ||
| protocol: TCP | ||
| - port: https-self | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: kube-state-metrics | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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,21 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: metrics-server | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: https | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: metrics-server | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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,21 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: monitoring-plugin | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: https | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: monitoring-plugin | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
23 changes: 23 additions & 0 deletions
23
assets/openshift-state-metrics/network-policy-downstream.yaml
This file contains hidden or 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,23 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: openshift-state-metrics | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: https-main | ||
| protocol: TCP | ||
| - port: https-self | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: openshift-state-metrics | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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,21 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: prometheus | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: grpc | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: prometheus | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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,21 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: prometheus-operator | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: https | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: prometheus-operator | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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,21 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: telemeter-client | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: https | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: telemeter-client | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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,21 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| labels: | ||
| app.kubernetes.io/managed-by: cluster-monitoring-operator | ||
| app.kubernetes.io/part-of: openshift-monitoring | ||
| name: thanos-querier | ||
| namespace: openshift-monitoring | ||
| spec: | ||
| egress: | ||
| - {} | ||
| ingress: | ||
| - ports: | ||
| - port: tenancy | ||
| protocol: TCP | ||
| podSelector: | ||
| matchLabels: | ||
| app.kubernetes.io/name: thanos-query | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress |
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.