Skip to content

Commit

Permalink
Adding the final scoop chart
Browse files Browse the repository at this point in the history
  • Loading branch information
Yashasvi Pareta authored and Yashasvi Pareta committed Aug 14, 2024
1 parent e721690 commit 072b483
Show file tree
Hide file tree
Showing 4 changed files with 52 additions and 30 deletions.
10 changes: 6 additions & 4 deletions charts/scoop/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
apiVersion: v1
appVersion: 1.16.0
name: devtron-scoop
description: Chart to deploy scoop
type: application
version: 1.0.1
appVersion: "1.16.0"
maintainers:
- email: [email protected]
name: Devops-Team DEVTRON
name: devtron-scoop
type: application
version: 1.0.1


8 changes: 4 additions & 4 deletions charts/scoop/templates/deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ spec:
serviceAccountName: scoop-sa
terminationGracePeriodSeconds: 30

{{- if $.Values.scoop.existingImagePullSecret }}
{{- if $.Values.scoop.imagePullSecrets.existingImagePullSecret }}
imagePullSecrets:
- name: {{ $.Values.scoop.existingImagePullSecret }}
- name: {{ $.Values.scoop.imagePullSecrets.existingImagePullSecret }}
{{- else }}
{{- if $.Values.secrets.enabled }}
{{- if $.Values.scoop.imagePullSecrets.enabled }}
imagePullSecrets:
- name: {{ $.Values.secrets.name }}
- name: scoop-imagepull-secret
{{- end }}
{{- end }}
restartPolicy: Always
Expand Down
29 changes: 24 additions & 5 deletions charts/scoop/templates/secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,30 @@ kind: Secret
metadata:
name: {{ $.Values.secrets.name }}
namespace: {{ $.Values.scoopNamespace | default .Release.Namespace }}
type: {{ $.Values.secrets.type }}
type: Opaque
{{- if $.Values.secrets.data }}
data:
{{- range $.Values.secrets.data }}
{{ .key | quote }}: {{ .value | b64enc | quote }}
{{- end }}
{{ toYaml $.Values.secrets.data | b64enc | indent 2 }}
{{- end }}
{{- end }}
{{- end }}

---

{{- if and $.Values.scoop.imagePullSecrets.enabled }}
{{- if not $.Values.scoop.imagePullSecrets.existingImagePullSecret }}
apiVersion: v1
kind: Secret
metadata:
name: scoop-imagepull-secret
namespace: {{ $.Values.scoopNamespace | default .Release.Namespace }}
type: kubernetes.io/dockerconfigjson
{{- if $.Values.scoop.imagePullSecrets.data}}
data:
{{- if $.Values.scoop.imagePullSecrets.data.value }}
.dockerconfigjson: {{ $.Values.scoop.imagePullSecrets.data.value | b64enc | quote }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}


35 changes: 18 additions & 17 deletions charts/scoop/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,22 @@

scoopNamespace: ""
# namespace where all the resource will be created

service:
type: ClusterIP
port: 80

# If both existingImagePullSecret and imagePullSecrets are present, existingImagePullSecret will be given preference.
scoop:
replicaCount: 1
existingImagePullSecret: ""
# Set enabled to true if you want to pass the values of secret.yaml from SecretRef
secrets:
name: scoop-secret
type: Opaque
## for docker hub secret
#type: kubernetes.io/dockerconfigjson
enabled: true
data:
## When you are creating secret for docker hub please use below syntax keep values in single quote only
# - key: .dockerconfigjson
# value: '{"auths":{"https://index.docker.io/v1/":{"username":"example_user","password":"XXXXXXXXX"}}}'
- key: db-username
value: "root"
- key: db-pass
value: "1234567"
image: ""
imagePullSecrets:
existingImagePullSecret: ""
enabled: true
data:
value: []
## When you are creating secret for docker hub please use below syntax keep values in single quote only
## value: '{"auths":{"https://index.docker.io/v1/":{"username":"example_user","password":"XXXXXXXXX"}}}'


env:
- name: X-PASS-KEY
Expand Down Expand Up @@ -58,6 +50,15 @@ ConfigMap:
enabled: true
data: []



# Set enabled to true if you want to pass the values of secret.yaml from SecretRef
secrets:
name: scoop-secret
enabled: true
data: []



volumes:
# - name: log-volume
Expand Down

0 comments on commit 072b483

Please sign in to comment.