Skip to content

Commit 168c899

Browse files
authored
Add example SCC for daemonset (#95)
* Add example SCC for daemonset --------- Signed-off-by: Ciara Stacke <[email protected]>
1 parent be15f97 commit 168c899

File tree

3 files changed

+41
-2
lines changed

3 files changed

+41
-2
lines changed

docs/manual-installation.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@ This will deploy the operator in the `nginx-ingress-operator-system` namespace.
3131
3232
3. `OpenShift` Additional steps:
3333
34-
In order to deploy NGINX Ingress Controller instances into OpenShift environments, a new SCC is required to be created on the cluster which will be used to bind the specific required capabilities to the NGINX Ingress service account(s). To do so, please run the following command (assuming you are logged in with administrator access to the cluster):
34+
In order to deploy NGINX Ingress Controller instances into OpenShift environments, a new SCC is required to be created on the cluster which will be used to bind the specific required capabilities to the NGINX Ingress service account(s). To do so for NIC deployments, please run the following command (assuming you are logged in with administrator access to the cluster):
3535
3636
`kubectl apply -f https://raw.githubusercontent.com/nginxinc/nginx-ingress-helm-operator/v1.4.1/resources/scc.yaml`
37+
38+
Alternatively, to create an SCC for NIC daemonsets, please run this command:
39+
40+
`kubectl apply -f https://raw.githubusercontent.com/nginxinc/nginx-ingress-helm-operator/v1.4.1/resources/scc-daemonset.yaml`
41+
42+
You can now deploy the NGINX Ingress Controller instances.

docs/openshift-installation.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,12 @@ OpenShift will install the NGINX Ingress Operator:
1919

2020
Additional steps:
2121

22-
In order to deploy NGINX Ingress Controller instances into OpenShift environments, a new SCC is required to be created on the cluster which will be used to bind the specific required capabilities to the NGINX Ingress service account(s). To do so, please run the following command (assuming you are logged in with administrator access to the cluster):
22+
In order to deploy NGINX Ingress Controller instances into OpenShift environments, a new SCC is required to be created on the cluster which will be used to bind the specific required capabilities to the NGINX Ingress service account(s). To do so for NIC deployments, please run the following command (assuming you are logged in with administrator access to the cluster):
2323

2424
`kubectl apply -f https://raw.githubusercontent.com/nginxinc/nginx-ingress-helm-operator/v1.4.1/resources/scc.yaml`
2525

26+
Alternatively, to create an SCC for NIC daemonsets, please run this command:
27+
28+
`kubectl apply -f https://raw.githubusercontent.com/nginxinc/nginx-ingress-helm-operator/v1.3.1/resources/scc-daemonset.yaml`
29+
2630
You can now deploy the NGINX Ingress Controller instances.

resources/scc-daemonset.yaml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Create SCC for IC resources
2+
kind: SecurityContextConstraints
3+
apiVersion: security.openshift.io/v1
4+
metadata:
5+
name: nginx-ingress-admin
6+
allowPrivilegedContainer: false
7+
runAsUser:
8+
type: MustRunAs
9+
uid: 101
10+
seLinuxContext:
11+
type: MustRunAs
12+
fsGroup:
13+
type: MustRunAs
14+
supplementalGroups:
15+
type: MustRunAs
16+
allowHostNetwork: false
17+
allowHostPID: false
18+
allowHostPorts: true
19+
allowHostDirVolumePlugin: false
20+
allowHostIPC: false
21+
readOnlyRootFilesystem: false
22+
seccompProfiles:
23+
- runtime/default
24+
volumes:
25+
- secret
26+
requiredDropCapabilities:
27+
- ALL
28+
users:
29+
- 'system:serviceaccount:*:nginx-ingress'

0 commit comments

Comments
 (0)