-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: add netpols and monitoring (#81)
## Description ... ## Related Issue Fixes #76 ## Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Other (security config, docs update, etc) ## Checklist before merging - [ ] Test, docs, adr added or updated as needed - [ ] [Contributor Guide Steps](https://github.com/defenseunicorns/uds-package-gitlab-runner/blob/main/CONTRIBUTING.md#developer-workflow) followed --------- Co-authored-by: Wayne Starr <Racer159@users.noreply.github.com> Release-As: v16.11.0-uds.1
- Loading branch information
1 parent
8dbb0ea
commit 71c40fb
Showing
10 changed files
with
106 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
name: {{ .Values.runnerNamespace }} | ||
labels: | ||
istio-injection: enabled | ||
name: {{ .Values.sandboxNamespace }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
kind: RoleBinding | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
metadata: | ||
name: {{ .Values.runnerNamespace }} | ||
namespace: {{ .Values.runnerNamespace }} | ||
name: {{ .Values.sandboxNamespace }} | ||
namespace: {{ .Values.sandboxNamespace }} | ||
subjects: | ||
- kind: ServiceAccount | ||
name: default | ||
name: {{ .Values.serviceAccountName }} | ||
namespace: gitlab-runner | ||
roleRef: | ||
apiGroup: "" | ||
kind: ClusterRole | ||
name: {{ .Values.runnerNamespace }} | ||
name: {{ .Values.sandboxNamespace }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
apiVersion: uds.dev/v1alpha1 | ||
kind: Package | ||
metadata: | ||
name: gitlab-runner-sandbox | ||
namespace: {{ .Values.sandboxNamespace }} | ||
spec: | ||
network: | ||
allow: | ||
- direction: Egress | ||
selector: | ||
uds/network-access-gitlab: "true" | ||
remoteNamespace: gitlab | ||
remoteSelector: | ||
app: webservice | ||
port: 8181 | ||
|
||
- direction: Ingress | ||
selector: | ||
uds/network-access-gitlab: "true" | ||
remoteNamespace: gitlab-runner | ||
remoteSelector: | ||
app: gitlab-runner | ||
|
||
{{- range .Values.customSandbox }} | ||
- direction: {{ .direction }} | ||
selector: | ||
{{ .selector | toYaml | nindent 10 }} | ||
{{- if not .remoteGenerated }} | ||
remoteNamespace: {{ .remoteNamespace }} | ||
remoteSelector: | ||
{{ .remoteSelector | toYaml | nindent 10 }} | ||
port: {{ .port }} | ||
{{- else }} | ||
remoteGenerated: {{ .remoteGenerated }} | ||
{{- end }} | ||
description: {{ .description }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,10 @@ | ||
runnerNamespace: "gitlab-runner-sandbox" | ||
sandboxNamespace: "gitlab-runner-sandbox" | ||
serviceAccountName: "gitlab-runner" | ||
custom: [] | ||
# - direction: Egress | ||
# remoteGenerated: Anywhere | ||
# description: "Egress from to external GitLab" | ||
customSandbox: [] | ||
# - direction: Egress | ||
# remoteGenerated: Anywhere | ||
# description: "Egress from to external GitLab" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
runnerNamespace: "###ZARF_VAR_JOB_RUNNER_NAMESPACE###" | ||
sandboxNamespace: "###ZARF_VAR_JOB_RUNNER_NAMESPACE###" | ||
serviceAccountName: "gitlab-runner" |