Skip to content

Commit

Permalink
Provide a writable location for flexvolume plugins
Browse files Browse the repository at this point in the history
Fix tests and add a note about how to update testdata
  • Loading branch information
gnufied committed Jan 18, 2019
1 parent f9ca131 commit c94174c
Show file tree
Hide file tree
Showing 19 changed files with 73 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pkg/controller/template/test_data/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
## Updating test data after making changes to original

test data templates can be updated via:

```
go test ./pkg/controller/template/... -u
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ contents: |
--minimum-container-ttl-duration=6m0s \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider=aws \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
\
--anonymous-auth=false \
--register-with-taints=node-role.kubernetes.io/master=:NoSchedule \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ contents: |
--minimum-container-ttl-duration=6m0s \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider= \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
\
--anonymous-auth=false \
--register-with-taints=node-role.kubernetes.io/master=:NoSchedule \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ contents: |
--minimum-container-ttl-duration=6m0s \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider= \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
\
--anonymous-auth=false \
--register-with-taints=node-role.kubernetes.io/master=:NoSchedule \
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
contents:
source: data:,
verification: {}
filesystem: root
mode: 493
path: /etc/kubernetes/kubelet-plugins/volume/exec/.dummy
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ contents: |
--allow-privileged \
--node-labels=node-role.kubernetes.io/worker \
--minimum-container-ttl-duration=6m0s \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider=aws \
\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ contents: |
--allow-privileged \
--node-labels=node-role.kubernetes.io/worker \
--minimum-container-ttl-duration=6m0s \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider= \
\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ contents: |
--allow-privileged \
--node-labels=node-role.kubernetes.io/worker \
--minimum-container-ttl-duration=6m0s \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider= \
\
Expand Down
5 changes: 5 additions & 0 deletions templates/master/00-master/_base/files/volume-plugins.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
filesystem: "root"
mode: 0755
path: "/etc/kubernetes/kubelet-plugins/volume/exec/.dummy"
contents:
inline: |
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ contents: |
--minimum-container-ttl-duration=6m0s \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider={{cloudProvider .}} \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
{{.CloudProviderConfig -}} \
--anonymous-auth=false \
--register-with-taints=node-role.kubernetes.io/master=:NoSchedule \
Expand Down
5 changes: 5 additions & 0 deletions templates/worker/00-worker/_base/files/volume-plugins.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
filesystem: "root"
mode: 0755
path: "/etc/kubernetes/kubelet-plugins/volume/exec/.dummy"
contents:
inline: |
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ contents: |
--allow-privileged \
--node-labels=node-role.kubernetes.io/worker \
--minimum-container-ttl-duration=6m0s \
--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume/exec \
--client-ca-file=/etc/kubernetes/ca.crt \
--cloud-provider={{cloudProvider .}} \
{{.CloudProviderConfig -}} \
Expand Down

0 comments on commit c94174c

Please sign in to comment.