Skip to content
This repository was archived by the owner on Jul 19, 2023. It is now read-only.

Commit 956424d

Browse files
authored
Merge pull request #444 from glindstedt/patch-1
Stricter default for `podSecurityContext`
2 parents 6920305 + c56e96d commit 956424d

File tree

5 files changed

+17
-1
lines changed

5 files changed

+17
-1
lines changed

operations/phlare/helm/phlare/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@
4040
| phlare.podAnnotations."phlare.grafana.com/port" | string | `"4100"` | |
4141
| phlare.podAnnotations."phlare.grafana.com/scrape" | string | `"true"` | |
4242
| phlare.podSecurityContext.fsGroup | int | `10001` | |
43+
| phlare.podSecurityContext.runAsNonRoot | bool | `true` | |
44+
| phlare.podSecurityContext.runAsUser | int | `10001` | |
4345
| phlare.replicaCount | int | `1` | |
4446
| phlare.resources | object | `{}` | |
4547
| phlare.securityContext | object | `{}` | |

operations/phlare/helm/phlare/rendered/micro-services.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -698,6 +698,8 @@ spec:
698698
serviceAccountName: phlare-dev
699699
securityContext:
700700
fsGroup: 10001
701+
runAsNonRoot: true
702+
runAsUser: 10001
701703
containers:
702704
- name: "agent"
703705
securityContext:
@@ -775,6 +777,8 @@ spec:
775777
serviceAccountName: phlare-dev
776778
securityContext:
777779
fsGroup: 10001
780+
runAsNonRoot: true
781+
runAsUser: 10001
778782
containers:
779783
- name: "distributor"
780784
securityContext:
@@ -851,6 +855,8 @@ spec:
851855
serviceAccountName: phlare-dev
852856
securityContext:
853857
fsGroup: 10001
858+
runAsNonRoot: true
859+
runAsUser: 10001
854860
containers:
855861
- name: "querier"
856862
securityContext:
@@ -1024,6 +1030,8 @@ spec:
10241030
serviceAccountName: phlare-dev
10251031
securityContext:
10261032
fsGroup: 10001
1033+
runAsNonRoot: true
1034+
runAsUser: 10001
10271035
containers:
10281036
- name: "ingester"
10291037
securityContext:

operations/phlare/helm/phlare/rendered/single-binary.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,8 @@ spec:
212212
serviceAccountName: phlare-dev
213213
securityContext:
214214
fsGroup: 10001
215+
runAsNonRoot: true
216+
runAsUser: 10001
215217
containers:
216218
- name: "phlare"
217219
securityContext:

operations/phlare/helm/phlare/values.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ phlare:
4242

4343
podSecurityContext:
4444
fsGroup: 10001
45+
runAsUser: 10001
46+
runAsNonRoot: true
4547

4648
securityContext:
4749
{}

operations/phlare/jsonnet/values.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,9 @@
6464
"phlare.grafana.com/scrape": "true"
6565
},
6666
"podSecurityContext": {
67-
"fsGroup": 10001
67+
"fsGroup": 10001,
68+
"runAsNonRoot": true,
69+
"runAsUser": 10001
6870
},
6971
"replicaCount": 1,
7072
"resources": {},

0 commit comments

Comments
 (0)