Skip to content

Commit

Permalink
Merge branch 'master' into tag-snapshots
Browse files Browse the repository at this point in the history
  • Loading branch information
jcodybaker authored Apr 22, 2019
2 parents 3f26f3d + fb1c08d commit 6e3c9dc
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 9 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
[[GH-143]](https://github.com/digitalocean/csi-digitalocean/pull/143)
* Add tagging support for Volume snapshots via the new `--do-tag` flag
[[GH-145]](https://github.com/digitalocean/csi-digitalocean/pull/145)
* Fix race in snapshot integration test.
[[GH-146]](https://github.com/digitalocean/csi-digitalocean/pull/146)

## v1.0.0 - 2018.12.19

Expand Down
6 changes: 2 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ BRANCH ?= $(shell git rev-parse --abbrev-ref HEAD)
LDFLAGS ?= -X github.com/digitalocean/csi-digitalocean/driver.version=${VERSION} -X github.com/digitalocean/csi-digitalocean/driver.commit=${COMMIT} -X github.com/digitalocean/csi-digitalocean/driver.gitTreeState=${GIT_TREE_STATE}
PKG ?= github.com/digitalocean/csi-digitalocean/cmd/do-csi-plugin

## Bump the version in the version file. Set BUMP to [ major | minor | patch ]
BUMP := patch
VERSION ?= $(shell cat VERSION)

all: test
Expand All @@ -20,8 +18,8 @@ publish: compile build push clean

.PHONY: bump-version
bump-version:
@go get -u github.com/jessfraz/junk/sembump # update sembump tool
$(eval NEW_VERSION = $(shell sembump --kind $(BUMP) $(VERSION)))
@[ "${NEW_VERSION}" ] || ( echo "NEW_VERSION must be set (ex. make NEW_VERSION=v1.x.x bump-version)"; exit 1 )
@(echo ${NEW_VERSION} | grep -E "^v") || ( echo "NEW_VERSION must be a semver ('v' prefix is required)"; exit 1 )
@echo "Bumping VERSION from $(VERSION) to $(NEW_VERSION)"
@echo $(NEW_VERSION) > VERSION
@cp deploy/kubernetes/releases/csi-digitalocean-${VERSION}.yaml deploy/kubernetes/releases/csi-digitalocean-${NEW_VERSION}.yaml
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,19 +36,19 @@ bumped following the rules below:
</thead>
<tbody>
<tr>
<td>v0.1.0 - v0.2.x</td>
<td>v0.1.x - v0.2.x</td>
<td>yes</td>
<td>no</td>
<td>no</td>
</tr>
<tr>
<td>v0.3.0 - v0.4.x</td>
<td>v0.3.x - v0.4.x</td>
<td>no</td>
<td>yes</td>
<td>no</td>
</tr>
<tr>
<td>v1.0.0 - v1.0.x</td>
<td>v1.0.x - v1.0.x</td>
<td>no</td>
<td>no</td>
<td>yes</td>
Expand Down Expand Up @@ -226,7 +226,7 @@ Dependencies are managed via [Go modules](https://github.com/golang/go/wiki/Modu
To release a new version bump first the version:

```
$ make bump-version
$ make NEW_VERSION=v1.0.0 bump-version
```

Make sure everything looks good. Create a new branch with all changes:
Expand Down
20 changes: 19 additions & 1 deletion test/kubernetes/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,24 @@ func TestSnapshot_Create(t *testing.T) {
Name: "my-csi-app-2",
},
Spec: v1.PodSpec{
// Write the data in an InitContainer so that we can guarantee
// it's been written before we reach running in the main container.
InitContainers: []v1.Container{
{
Name: "my-csi",
Image: "busybox",
VolumeMounts: []v1.VolumeMount{
{
MountPath: "/data",
Name: volumeName,
},
},
Command: []string{
"sh", "-c",
"echo testcanary > /data/canary && sync",
},
},
},
Containers: []v1.Container{
{
Name: "my-csi-app",
Expand All @@ -370,7 +388,7 @@ func TestSnapshot_Create(t *testing.T) {
},
Command: []string{
"sh", "-c",
"echo testcanary > /data/canary && sleep 1000000",
"sleep 1000000",
},
},
},
Expand Down

0 comments on commit 6e3c9dc

Please sign in to comment.