Skip to content

Commit 60cac04

Browse files
authored
Merge pull request #168 from Clovel/feature/config-path
[Fixes #135] Updated chart to accept configPath to fix distribution's 3.0.0 breaking change
2 parents 458381c + e3a6eb4 commit 60cac04

File tree

5 files changed

+7
-4
lines changed

5 files changed

+7
-4
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ their default values.
7979
| `secrets.swift.password` | Password for Swift configuration | `nil` |
8080
| `secrets.haSharedSecret` | Shared secret for Registry | `nil` |
8181
| `configData` | Configuration hash for docker | `nil` |
82+
| `configPath` | Configuration mount point in docker, `/etc/docker/registry` for registry version 2, `/etc/distribution` for version 3 | `/etc/docker/registry` |
8283
| `s3.region` | S3 region | `nil` |
8384
| `s3.regionEndpoint` | S3 region endpoint | `nil` |
8485
| `s3.bucket` | S3 bucket name | `nil` |

templates/_helpers.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ We truncate at 63 chars because some Kubernetes name fields are limited to this
153153

154154
{{- define "docker-registry.volumeMounts" -}}
155155
- name: "{{ template "docker-registry.fullname" . }}-config"
156-
mountPath: "/etc/docker/registry"
156+
mountPath: {{ .Values.configPath }}
157157

158158
{{- if .Values.secrets.htpasswd }}
159159
- name: auth

templates/cronjob.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ spec:
5858
- /bin/registry
5959
- garbage-collect
6060
- --delete-untagged={{ .Values.garbageCollect.deleteUntagged }}
61-
- /etc/docker/registry/config.yml
61+
- {{ .Values.configPath }}/config.yml
6262
{{- if .Values.garbageCollect.resources }}
6363
resources:
6464
{{- toYaml .Values.garbageCollect.resources | nindent 16 }}

templates/deployment.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ spec:
6060
command:
6161
- /bin/registry
6262
- serve
63-
- /etc/docker/registry/config.yml
63+
- {{ .Values.configPath }}/config.yml
6464
ports:
6565
- containerPort: 5000
6666
{{- if .Values.metrics.enabled }}

values.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ serviceAccount:
1919

2020
image:
2121
repository: registry
22-
tag: 2.8.1
22+
tag: 3.0.0
2323
pullPolicy: IfNotPresent
2424
# imagePullSecrets:
2525
# - name: docker
@@ -134,6 +134,7 @@ metrics:
134134
labels: {}
135135
rules: {}
136136

137+
configPath: /etc/distribution
137138
configData:
138139
version: 0.1
139140
log:
@@ -177,6 +178,7 @@ securityContext:
177178
fsGroupChangePolicy: Always
178179
sysctls: []
179180
supplementalGroups: []
181+
runAsUser: 1000
180182
fsGroup: 1000
181183

182184
priorityClassName: ""

0 commit comments

Comments
 (0)