Skip to content

Commit

Permalink
Update driver version to 0.1.0-alpha
Browse files Browse the repository at this point in the history
Switch to use golang1.11.1-stretch as build image so that we can
delegate to make file for binary compilation without duplicating the
logic in both makefile and dockerfile.
  • Loading branch information
Cheng Pan committed Nov 2, 2018
1 parent 1cc8754 commit a738f2d
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.11.1-alpine3.8 as builder
FROM golang:1.11.1-stretch as builder
WORKDIR /go/src/github.com/kubernetes-sigs/aws-ebs-csi-driver
ADD . .
RUN CGO_ENABLED=0 GOOS=linux go build -o bin/aws-ebs-csi-driver ./cmd/aws-ebs-csi-driver
RUN make

FROM amazonlinux:2
RUN yum install ca-certificates e2fsprogs -y
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
# limitations under the License.

IMAGE=amazon/aws-ebs-csi-driver
VERSION=testing
VERSION=0.1.0-alpha

.PHONY: aws-ebs-csi-driver
aws-ebs-csi-driver:
mkdir -p bin
go build -o bin/aws-ebs-csi-driver ./cmd/aws-ebs-csi-driver
CGO_ENABLED=0 GOOS=linux go build -ldflags "-X github.com/kubernetes-sigs/aws-ebs-csi-driver/pkg/driver.vendorVersion=${VERSION}" -o bin/aws-ebs-csi-driver ./cmd/

.PHONY: test
test:
Expand Down
File renamed without changes.
10 changes: 7 additions & 3 deletions pkg/driver/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,13 @@ import (
)

const (
driverName = "com.amazon.aws.csi.ebs"
vendorVersion = "0.0.1" // FIXME
topologyKey = driverName + "/zone"
driverName = "com.amazon.aws.csi.ebs"
topologyKey = driverName + "/zone"
)

var (
// vendorVersion is the version driver and is set during build
vendorVersion string
)

type Driver struct {
Expand Down

0 comments on commit a738f2d

Please sign in to comment.