Skip to content

Commit

Permalink
netpol: rename option to interNamespaceAccessLabels
Browse files Browse the repository at this point in the history
  • Loading branch information
consideRatio committed Oct 20, 2020
1 parent ddb1a47 commit 0f0ea2b
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion jupyterhub/templates/hub/netpol.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ spec:
- podSelector:
matchLabels:
hub.jupyter.org/network-access-hub: "true"
{{- if eq .Values.hub.networkPolicy.interNamespaceLabeledIngress "allow" }}
{{- if eq .Values.hub.networkPolicy.interNamespaceAccessLabels "accept" }}
namespaceSelector:
matchLabels: {} # without this, the podSelector would only consider pods in the local namespace
# source 2 - pods in labeled namespaces
Expand Down
2 changes: 1 addition & 1 deletion jupyterhub/templates/proxy/autohttps/netpol.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ spec:
- podSelector:
matchLabels:
hub.jupyter.org/network-access-proxy-http: "true"
{{- if eq .Values.proxy.traefik.networkPolicy.interNamespaceLabeledIngress "allow" }}
{{- if eq .Values.proxy.traefik.networkPolicy.interNamespaceAccessLabels "accept" }}
namespaceSelector:
matchLabels: {} # without this, the podSelector would only consider pods in the local namespace
# source 2 - pods in labeled namespaces
Expand Down
4 changes: 2 additions & 2 deletions jupyterhub/templates/proxy/netpol.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ spec:
- podSelector:
matchLabels:
hub.jupyter.org/network-access-proxy-http: "true"
{{- if eq .Values.proxy.chp.networkPolicy.interNamespaceLabeledIngress "allow" }}
{{- if eq .Values.proxy.chp.networkPolicy.interNamespaceAccessLabels "accept" }}
namespaceSelector:
matchLabels: {} # without this, the podSelector would only consider pods in the local namespace
# source 2 - pods in labeled namespaces
Expand All @@ -69,7 +69,7 @@ spec:
- podSelector:
matchLabels:
hub.jupyter.org/network-access-proxy-api: "true"
{{- if eq .Values.proxy.chp.networkPolicy.interNamespaceLabeledIngress "allow" }}
{{- if eq .Values.proxy.chp.networkPolicy.interNamespaceAccessLabels "accept" }}
namespaceSelector:
matchLabels: {} # without this, the podSelector would only consider pods in the local namespace
# source 2 - pods in labeled namespaces
Expand Down
2 changes: 1 addition & 1 deletion jupyterhub/templates/singleuser/netpol.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ spec:
- podSelector:
matchLabels:
hub.jupyter.org/network-access-singleuser: "true"
{{- if eq .Values.singleuser.networkPolicy.interNamespaceLabeledIngress "allow" }}
{{- if eq .Values.singleuser.networkPolicy.interNamespaceAccessLabels "accept" }}
namespaceSelector:
matchLabels: {} # without this, the podSelector would only consider pods in the local namespace
# source 2 - pods in labeled namespaces
Expand Down
8 changes: 4 additions & 4 deletions jupyterhub/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ hub:
- to:
- ipBlock:
cidr: 0.0.0.0/0
interNamespaceLabeledIngress: block
interNamespaceAccessLabels: ignore
allowedIngressPorts: []
allowNamedServers: false
namedServerLimitPerUser:
Expand Down Expand Up @@ -200,7 +200,7 @@ proxy:
- to:
- ipBlock:
cidr: 0.0.0.0/0
interNamespaceLabeledIngress: allow
interNamespaceAccessLabels: accept
allowedIngressPorts: [http, https]
# traefik relates to the autohttps pod, which is responsible for TLS
# termination when proxy.https.type=letsencrypt.
Expand Down Expand Up @@ -233,7 +233,7 @@ proxy:
- to:
- ipBlock:
cidr: 0.0.0.0/0
interNamespaceLabeledIngress: allow
interNamespaceAccessLabels: accept
allowedIngressPorts: [http, https]
secretSync:
containerSecurityContext:
Expand Down Expand Up @@ -329,7 +329,7 @@ singleuser:
cidr: 0.0.0.0/0
except:
- 169.254.169.254/32
interNamespaceLabeledIngress: block
interNamespaceAccessLabels: ignore
allowedIngressPorts: []
events: true
extraAnnotations: {}
Expand Down
8 changes: 4 additions & 4 deletions tools/templates/lint-and-validate-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ hub:
- to:
- ipBlock:
cidr: 0.0.0.0/0
interNamespaceLabeledIngress: block
interNamespaceAccessLabels: ignore
allowedIngressPorts: []
allowNamedServers: true
nodeSelector:
Expand Down Expand Up @@ -135,7 +135,7 @@ proxy:
- to:
- ipBlock:
cidr: 0.0.0.0/0
interNamespaceLabeledIngress: allow
interNamespaceAccessLabels: accept
allowedIngressPorts: [http, https]
traefik:
resources:
Expand Down Expand Up @@ -165,7 +165,7 @@ proxy:
- to:
- ipBlock:
cidr: 0.0.0.0/0
interNamespaceLabeledIngress: allow
interNamespaceAccessLabels: accept
allowedIngressPorts: [http, https]
secretSync:
resources:
Expand Down Expand Up @@ -294,7 +294,7 @@ singleuser:
cidr: 0.0.0.0/0
except:
- 169.254.169.254/32
interNamespaceLabeledIngress: block
interNamespaceAccessLabels: ignore
allowedIngressPorts: []
events: true
extraLabels: {}
Expand Down

0 comments on commit 0f0ea2b

Please sign in to comment.