Skip to content

Commit

Permalink
Merge pull request #1 from brtknr/appVersion-1.19
Browse files Browse the repository at this point in the history
Make cloud-config/cacert volume/volumeMounts configurable
  • Loading branch information
brtkwr authored Sep 28, 2020
2 parents 1b82117 + 9a378f3 commit 5707d06
Show file tree
Hide file tree
Showing 9 changed files with 55 additions and 27 deletions.
4 changes: 2 additions & 2 deletions charts/cinder-csi-plugin/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
apiVersion: v1
appVersion: "v1.19.0"
appVersion: v1.19.0
description: Cinder CSI Chart for OpenStack
name: openstack-cinder-csi
version: 1.2.1
version: 1.2.2
home: https://github.com/kubernetes/cloud-provider-openstack
icon: https://github.com/kubernetes/kubernetes/blob/master/logo/logo.png
maintainers:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ spec:
- name: socket-dir
mountPath: /var/lib/csi/sockets/pluginproxy/
- name: cinder-csi-plugin
image: "{{ .Values.csi.plugin.image.repository }}:{{ .Values.csi.plugin.image.tag }}"
image: "{{ .Values.csi.plugin.image.repository }}:{{ .Values.csi.plugin.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.csi.plugin.image.pullPolicy }}
args:
- /bin/cinder-csi-plugin
Expand All @@ -95,13 +95,8 @@ spec:
volumeMounts:
- name: socket-dir
mountPath: /csi
- name: cacert
mountPath: /etc/cacert
readOnly: true
{{- .Values.csi.plugin.volumeMounts | toYaml | trimSuffix "\n" | nindent 12 }}
volumes:
- name: cacert
hostPath:
path: /etc/cacert
type: Directory
- name: socket-dir
emptyDir:
{{ .Values.csi.plugin.volumes | toYaml | trimSuffix "\n" | nindent 8 }}
11 changes: 3 additions & 8 deletions charts/cinder-csi-plugin/templates/nodeplugin-daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ spec:
capabilities:
add: ["SYS_ADMIN"]
allowPrivilegeEscalation: true
image: "{{ .Values.csi.plugin.image.repository }}:{{ .Values.csi.plugin.image.tag }}"
image: "{{ .Values.csi.plugin.image.repository }}:{{ .Values.csi.plugin.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.csi.plugin.image.pullPolicy }}
args:
- /bin/cinder-csi-plugin
Expand All @@ -73,14 +73,8 @@ spec:
- name: pods-probe-dir
mountPath: /dev
mountPropagation: "HostToContainer"
- name: cacert
mountPath: /etc/cacert
readOnly: true
{{- .Values.csi.plugin.volumeMounts | toYaml | trimSuffix "\n" | nindent 12 }}
volumes:
- name: cacert
hostPath:
path: /etc/cacert
type: Directory
- name: socket-dir
hostPath:
path: /var/lib/kubelet/plugins/cinder.csi.openstack.org
Expand All @@ -101,3 +95,4 @@ spec:
hostPath:
path: /dev
type: Directory
{{ .Values.csi.plugin.volumes | toYaml | trimSuffix "\n" | nindent 8 }}
10 changes: 10 additions & 0 deletions charts/cinder-csi-plugin/templates/secret.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{{- if .Values.secret }}
apiVersion: v1
kind: Secret
metadata:
name: {{ .Values.secret.name }}
namespace: {{ .Release.NameSpace }}
type: Opaque
stringData:
{{ .Values.secret.data | toYaml | trimSuffix "\n" | nindent 2 }}
{{- end }}
30 changes: 29 additions & 1 deletion charts/cinder-csi-plugin/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,36 @@ csi:
plugin:
image:
repository: docker.io/k8scloudprovider/cinder-csi-plugin
tag: v1.19.0
pullPolicy: IfNotPresent
tag: # defaults to .Chart.AppVersion
volumes:
- name: cacert
hostPath:
path: /etc/cacert
- name: cloud-config
hostPath:
path: /etc/kubernetes
# secret:
# secretName: cinder-csi-cloud-config
volumeMounts:
- name: cacert
mountPath: /etc/cacert
readOnly: true
- name: cloud-config
mountPath: /etc/kubernetes
readOnly: true

secret:
# name: cinder-csi-cloud-config
# data:
# cloud-config: |-
# [Global]
# auth-url=http://openstack-control-plane
# user-id=user-id
# password=password
# trust-id=trust-id
# region=RegionOne
# ca-file=/etc/cacert/ca-bundle.crt

storageClass:
enabled: true
Expand Down
4 changes: 2 additions & 2 deletions charts/manila-csi-plugin/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
apiVersion: v1
appVersion: latest
appVersion: v1.19.0
description: Manila CSI Chart for OpenStack
name: openstack-manila-csi
version: 0.2.0
version: 0.2.1
home: http://github.com/kubernetes/cloud-provider-openstack
icon: https://github.com/kubernetes/kubernetes/blob/master/logo/logo.png
maintainers:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ spec:
capabilities:
add: ["SYS_ADMIN"]
allowPrivilegeEscalation: true
image: "{{ $.Values.csimanila.image.repository }}:{{ $.Values.csimanila.image.tag }}"
image: "{{ $.Values.csimanila.image.repository }}:{{ $.Values.csimanila.image.tag | default $.Chart.AppVersion }}"
command: ["/bin/sh", "-c",
'/bin/manila-csi-plugin
--v=5
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ spec:
capabilities:
add: ["SYS_ADMIN"]
allowPrivilegeEscalation: true
image: "{{ $.Values.csimanila.image.repository }}:{{ $.Values.csimanila.image.tag }}"
image: "{{ $.Values.csimanila.image.repository }}:{{ $.Values.csimanila.image.tag | default $.Chart.AppVersion }}"
command: ["/bin/sh", "-c",
'/bin/manila-csi-plugin
--v=5
Expand Down
8 changes: 4 additions & 4 deletions charts/manila-csi-plugin/values.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
nameOverride: ""
fullNameOverride: ""

# Base name of the CSI Manila driver
driverName: manila.csi.openstack.org

Expand Down Expand Up @@ -31,8 +34,8 @@ csimanila:
# Image spec
image:
repository: k8scloudprovider/manila-csi-plugin
tag: v1.19.0
pullPolicy: IfNotPresent
tag: # defaults to .Chart.AppVersion

# DeamonSet deployment
nodeplugin:
Expand Down Expand Up @@ -79,6 +82,3 @@ controllerplugin:
affinity: {}
# Use fullnameOverride to fully override the name of this component
# fullnameOverride: some-other-name

# Override the default app name using nameOverride
# nameOverride: some-other-name

0 comments on commit 5707d06

Please sign in to comment.