Skip to content

Commit

Permalink
Variabalize Git Server configs (#1133)
Browse files Browse the repository at this point in the history
This PR exposes variables for the Git Server in the init package to match the Zarf Registry:

- GIT_SERVER_EXISTING_PVC
- GIT_SERVER_PVC_SIZE
- GIT_SERVER_CPU_REQ
- GIT_SERVER_MEM_REQ
- GIT_SERVER_CPU_LIMIT
- GIT_SERVER_MEM_LIMIT

Fixes #1122 
Related to #1123
  • Loading branch information
jeff-mccoy authored Dec 15, 2022
1 parent c028831 commit 2ca10ab
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 4 deletions.
11 changes: 7 additions & 4 deletions packages/gitea/gitea-values.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
persistence:
storageClass: "###ZARF_STORAGE_CLASS###"
existingClaim: "###ZARF_VAR_GIT_SERVER_EXISTING_PVC###"
size: "###ZARF_VAR_GIT_SERVER_PVC_SIZE###"

gitea:
admin:
username: "###ZARF_GIT_PUSH###"
Expand All @@ -24,11 +27,11 @@ gitea:
FORCE_PRIVATE: true
resources:
requests:
cpu: "200m"
memory: "512Mi"
cpu: "###ZARF_VAR_GIT_SERVER_CPU_REQ###"
memory: "###ZARF_VAR_GIT_SERVER_MEM_REQ###"
limits:
cpu: "1"
memory: "2Gi"
cpu: "###ZARF_VAR_GIT_SERVER_CPU_LIMIT###"
memory: "###ZARF_VAR_GIT_SERVER_MEM_LIMIT###"

memcached:
enabled: false
Expand Down
25 changes: 25 additions & 0 deletions packages/gitea/zarf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,31 @@ kind: ZarfPackageConfig
metadata:
name: "init-package-git-server"

variables:
- name: GIT_SERVER_EXISTING_PVC
description: "Optional: Use an existing PVC for the git server instead of creating a new one. If this is set, the GIT_SERVER_PVC_SIZE variable will be ignored."
default: ""

- name: GIT_SERVER_PVC_SIZE
description: "The size of the persistent volume claim for git server"
default: "10Gi"

- name: GIT_SERVER_CPU_REQ
description: "The CPU request for git server"
default: "200m"

- name: GIT_SERVER_MEM_REQ
description: "The memory request for git server"
default: "512Mi"

- name: GIT_SERVER_CPU_LIMIT
description: "The CPU limit for git server"
default: "3"

- name: GIT_SERVER_MEM_LIMIT
description: "The memory limit for git server"
default: "2Gi"

components:
- name: git-server
description: "Add Gitea for serving gitops-based clusters in an airgap"
Expand Down

0 comments on commit 2ca10ab

Please sign in to comment.