From db492de23f91ba4463e0a27d9c004f90058399b7 Mon Sep 17 00:00:00 2001 From: Matthew Wong Date: Tue, 5 Oct 2021 13:10:08 -0700 Subject: [PATCH 1/2] Post-release v1.3.1 --- charts/aws-ebs-csi-driver/CHANGELOG.md | 14 +++++++++++++- charts/aws-ebs-csi-driver/Chart.yaml | 4 ++-- .../overlays/stable/ecr/kustomization.yaml | 2 +- .../kubernetes/overlays/stable/kustomization.yaml | 2 +- 4 files changed, 17 insertions(+), 5 deletions(-) diff --git a/charts/aws-ebs-csi-driver/CHANGELOG.md b/charts/aws-ebs-csi-driver/CHANGELOG.md index d0c2a3109c..44063d3739 100644 --- a/charts/aws-ebs-csi-driver/CHANGELOG.md +++ b/charts/aws-ebs-csi-driver/CHANGELOG.md @@ -1,9 +1,21 @@ # Helm chart -## v2.1.2 +## v2.3.1 + +* Bump app/driver version to `v1.3.1` + +## v2.3.0 + +* Support overriding controller `--default-fstype` flag via values + +## v2.2.1 * Bump app/driver version to `v1.3.0` +## v2.2.0 + +* Support setting imagePullPolicy for all containers + ## v2.1.1 * Bump app/driver version to `v1.2.1` diff --git a/charts/aws-ebs-csi-driver/Chart.yaml b/charts/aws-ebs-csi-driver/Chart.yaml index e8ddb805ba..5acf971ca1 100644 --- a/charts/aws-ebs-csi-driver/Chart.yaml +++ b/charts/aws-ebs-csi-driver/Chart.yaml @@ -1,8 +1,8 @@ apiVersion: v2 -appVersion: 1.3.0 +appVersion: 1.3.1 name: aws-ebs-csi-driver description: A Helm chart for AWS EBS CSI Driver -version: 2.1.2 +version: 2.3.1 kubeVersion: ">=1.17.0-0" home: https://github.com/kubernetes-sigs/aws-ebs-csi-driver sources: diff --git a/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml b/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml index 324e00e047..039a71581a 100644 --- a/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml +++ b/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml @@ -5,7 +5,7 @@ bases: images: - name: k8s.gcr.io/provider-aws/aws-ebs-csi-driver newName: 602401143452.dkr.ecr.us-west-2.amazonaws.com/eks/aws-ebs-csi-driver - newTag: v1.3.0 + newTag: v1.3.1 - name: k8s.gcr.io/sig-storage/csi-provisioner newName: public.ecr.aws/eks-distro/kubernetes-csi/external-provisioner newTag: v2.1.1-eks-1-18-3 diff --git a/deploy/kubernetes/overlays/stable/kustomization.yaml b/deploy/kubernetes/overlays/stable/kustomization.yaml index fecaa0005e..fdbf719099 100644 --- a/deploy/kubernetes/overlays/stable/kustomization.yaml +++ b/deploy/kubernetes/overlays/stable/kustomization.yaml @@ -4,7 +4,7 @@ bases: - ../../base images: - name: k8s.gcr.io/provider-aws/aws-ebs-csi-driver - newTag: v1.3.0 + newTag: v1.3.1 - name: k8s.gcr.io/sig-storage/csi-provisioner newTag: v2.1.1 - name: k8s.gcr.io/sig-storage/csi-attacher From fdc43c093c1f4dac5b2e76380b93f516a4954bde Mon Sep 17 00:00:00 2001 From: Matthew Wong Date: Wed, 6 Oct 2021 12:41:01 -0700 Subject: [PATCH 2/2] Fix windows NodePublish failing because mount target doesn't exist --- examples/kubernetes/windows/README.md | 4 +--- pkg/driver/node.go | 13 +++++++++---- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/examples/kubernetes/windows/README.md b/examples/kubernetes/windows/README.md index 8cbdbfb454..19a466fd75 100644 --- a/examples/kubernetes/windows/README.md +++ b/examples/kubernetes/windows/README.md @@ -1,7 +1,5 @@ ## Windows -**This example requires unreleased versions of csi-proxy and the driver that. It is intended for developers only for now. It will be updated once the driver has been released. Only basic read/write (mount/unmount and attach/detach) functionality has been tested, other features like resize don't work yet.** - This example shows how to create a EBS volume and consume it from a Windows container dynamically. @@ -9,7 +7,7 @@ This example shows how to create a EBS volume and consume it from a Windows cont 1. A 1.18+ Windows node. Windows support has only been tested on 1.18 EKS Windows nodes. https://docs.aws.amazon.com/eks/latest/userguide/windows-support.html 2. [csi-proxy](https://github.com/kubernetes-csi/csi-proxy) v1.0.0+ installed on the Windows node. -3. An image of the driver built for Windows. It can be built and pushed with the command `TAG=$MY_TAG REGISTRY=$MY_REGISTRY make all-push` where `MY_TAG` refers to the image tag to push and `MY_REGISTRY` to the destination image registry like "XXXXXXXXXXXX.dkr.ecr.us-west-2.amazonaws.com" +3. Driver v1.3.2 from GCR k8s.gcr.io/provider-aws/aws-ebs-csi-driver:v1.3.2. It can be built and pushed to another image registry with the command `TAG=$MY_TAG REGISTRY=$MY_REGISTRY make all-push` where `MY_TAG` refers to the image tag to push and `MY_REGISTRY` to the destination image registry like "XXXXXXXXXXXX.dkr.ecr.us-west-2.amazonaws.com" 4. The driver installed with the Node plugin on the Windows node and the Controller plugin on a Linux node: `helm upgrade --install aws-ebs-csi-driver --namespace kube-system ./charts/aws-ebs-csi-driver --set node.enableWindows=true --set image.repository=$MY_REGISTRY/aws-ebs-csi-driver --set image.tag=$MY_TAG` ## Usage diff --git a/pkg/driver/node.go b/pkg/driver/node.go index 95ad9ddc8e..068bfdd1e9 100644 --- a/pkg/driver/node.go +++ b/pkg/driver/node.go @@ -589,7 +589,7 @@ func (d *nodeService) nodePublishVolumeForBlock(req *csi.NodePublishVolumeReques //Checking if the target file is already mounted with a device. mounted, err := d.isMounted(source, target) if err != nil { - return status.Errorf(codes.Internal, "Could not mount %q at %q: %v", source, target, err) + return status.Errorf(codes.Internal, "Could not check if %q is mounted: %v", target, err) } if !mounted { @@ -626,7 +626,7 @@ func (d *nodeService) isMounted(source string, target string) (bool, error) { //After successful unmount, the device is ready to be mounted. return !notMnt, nil } - return !notMnt, status.Errorf(codes.Internal, "Could not mount %q at %q: %v", source, target, err) + return !notMnt, status.Errorf(codes.Internal, "Could not check if %q is a mount point: %v, %v", target, err, pathErr) } if !notMnt { @@ -634,7 +634,12 @@ func (d *nodeService) isMounted(source string, target string) (bool, error) { return !notMnt, nil } - return !notMnt, err + // Do not return os.IsNotExist error. Other errors were handled above. It is + // the responsibility of the caller to check whether the given target path + // exists (in Linux, the target mount directory must exist before mount is + // called on it) or not (in Windows, the target must NOT exist before a + // symlink is created at it) + return !notMnt, nil } func (d *nodeService) nodePublishVolumeForFileSystem(req *csi.NodePublishVolumeRequest, mountOptions []string, mode *csi.VolumeCapability_Mount) error { @@ -665,7 +670,7 @@ func (d *nodeService) nodePublishVolumeForFileSystem(req *csi.NodePublishVolumeR mounted, err := d.isMounted(source, target) if err != nil { - return status.Errorf(codes.Internal, "Could not mount %q at %q: %v", source, target, err) + return status.Errorf(codes.Internal, "Could not check if %q is mounted: %v", target, err) } if !mounted {