forked from bcgov/platform-services
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathquickstart-nsp.yaml
More file actions
35 lines (35 loc) · 984 Bytes
/
quickstart-nsp.yaml
File metadata and controls
35 lines (35 loc) · 984 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
apiVersion: template.openshift.io/v1
kind: Template
parameters:
- name: NAMESPACE
objects:
- apiVersion: security.devops.gov.bc.ca/v1alpha1
kind: NetworkSecurityPolicy
metadata:
name: egress-internet
spec:
description: "allow ${NAMESPACE} namespace to talk to the internet."
source:
- - $namespace=${NAMESPACE}
destination:
- - ext:network=any
- apiVersion: security.devops.gov.bc.ca/v1alpha1
kind: NetworkSecurityPolicy
metadata:
name: intra-namespace-comms
spec:
description: "allow ${NAMESPACE} namespace to talk to itself"
source:
- - $namespace=${NAMESPACE}
destination:
- - $namespace=${NAMESPACE}
- apiVersion: security.devops.gov.bc.ca/v1alpha1
kind: NetworkSecurityPolicy
metadata:
name: int-cluster-k8s-api-comms
spec:
description: "allow ${NAMESPACE} pods to talk to the k8s api"
destination:
- - int:network=internal-cluster-api-endpoint
source:
- - $namespace=${NAMESPACE}