Skip to content

Commit 168e2ef

Browse files
authored
fix remote runner for main.stage (#2230)
fix the remote runner for main.stage
1 parent 8d154e9 commit 168e2ef

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

lib/.changeset/v1.54.7.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Upgrade remote runner for main.stage

lib/k8s/environment/runner.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,12 @@ func job(chart cdk8s.Chart, props *Props) {
297297
Annotations: a.ConvertAnnotations(defaultRunnerPodAnnotations),
298298
},
299299
Spec: &k8s.PodSpec{
300+
SecurityContext: &k8s.PodSecurityContext{
301+
RunAsNonRoot: ptr.Ptr(true),
302+
RunAsUser: ptr.Ptr(float64(1001)),
303+
RunAsGroup: ptr.Ptr(float64(1001)),
304+
FsGroup: ptr.Ptr(float64(1001)),
305+
},
300306
ServiceAccountName: ptr.Ptr("default"),
301307
Containers: container(props),
302308
RestartPolicy: ptr.Ptr(restartPolicy),
@@ -467,5 +473,6 @@ func jobEnvVars(props *Props) *[]*k8s.EnvVar {
467473
for k, v := range env {
468474
cdk8sVars = append(cdk8sVars, a.EnvVarStr(k, v))
469475
}
476+
cdk8sVars = append(cdk8sVars, a.EnvVarStr("RUN_QUARANTINED_TESTS", "true"))
470477
return &cdk8sVars
471478
}

0 commit comments

Comments
 (0)