Skip to content
This repository has been archived by the owner on Feb 22, 2022. It is now read-only.

[stable/hlf-peer] Add docker config.json secret for private registry #23206

Merged
merged 1 commit into from
Jul 17, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion stable/hlf-peer/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v1
description: Hyperledger Fabric Peer chart (these charts are created by AID:Tech and are currently not directly associated with the Hyperledger project)
name: hlf-peer
version: 1.4.0
version: 1.5.0
appVersion: 1.4.3
keywords:
- blockchain
Expand Down
2 changes: 2 additions & 0 deletions stable/hlf-peer/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,8 @@ The following table lists the configurable parameters of the Hyperledger Fabric
| `ingress.hosts` | Ingress hostnames | `[]` |
| `ingress.tls` | Ingress TLS configuration | `[]` |
| `dockerSocketPath` | Docker Socket path | `/var/run/docker.sock` |
| `dockerConfig` | Docker Config file base 64 encoded | `null` |
| `dockerConfigMountPath` | Docker Config file mount path | `/root/.docker` |
| `peer.databaseType` | Database type to use (`goleveldb` or `CouchDB`) | `goleveldb` |
| `peer.couchdbInstance` | CouchDB chart name to use `cdb-peer1` | `cdb-peer1` |
| `peer.mspID` | ID of MSP the Peer belongs to | `Org1MSP` |
Expand Down
12 changes: 12 additions & 0 deletions stable/hlf-peer/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ spec:
- name: dockersocket
hostPath:
path: {{ .Values.dockerSocketPath }}
{{- if .Values.dockerConfig }}
- name: docker-config
secret:
secretName: {{ include "hlf-peer.fullname" . }}-dockerconfigjson
items:
- key: .dockerconfigjson
path: config.json
{{- end }}
{{- if .Values.secrets.peer.cert }}
- name: id-cert
secret:
Expand Down Expand Up @@ -163,6 +171,10 @@ spec:
name: data
- mountPath: /host/var/run/docker.sock
name: dockersocket
{{- if .Values.dockerConfig }}
- name: docker-config
mountPath: {{ .Values.dockerConfigMountPath }}
{{ end }}
{{- if .Values.secrets.peer.cert }}
- mountPath: /var/hyperledger/msp/signcerts
name: id-cert
Expand Down
9 changes: 9 additions & 0 deletions stable/hlf-peer/templates/secret.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{{- if .Values.dockerConfig }}
apiVersion: v1
kind: Secret
type: kubernetes.io/dockerconfigjson
metadata:
name: {{ include "hlf-peer.fullname" . }}-dockerconfigjson
data:
.dockerconfigjson: {{ .Values.dockerConfig }}
{{ end }}
5 changes: 5 additions & 0 deletions stable/hlf-peer/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@ service:
portRequest: 7051
portEvent: 7053

# Path of the docker socket on the host
dockerSocketPath: /var/run/docker.sock
# Docker config to be used to pull the images (base64'd)
dockerConfig: null
# Docker config mount path
dockerConfigMountPath: /root/.docker

ingress:
enabled: false
Expand Down