Skip to content

Commit

Permalink
Merge pull request #95 from JohnStrunk/r111
Browse files Browse the repository at this point in the history
Release 1.1.1
JohnStrunk authored Apr 24, 2020
2 parents 275131e + 0731ec2 commit 143318d
Showing 27 changed files with 1,411 additions and 182 deletions.
5 changes: 4 additions & 1 deletion .ci-scripts/pre-commit.sh
Original file line number Diff line number Diff line change
@@ -18,12 +18,15 @@ function run_check() {
shift

if [ -x "$(command -v "$exe")" ]; then
echo "===== $exe ====="
find . \
-path ./vendor -prune -o \
-path ./docs/_site -prune -o \
-path ./docs/vendor -prune -o \
-regextype egrep -iregex "$regex" -print0 | \
xargs -0rt -n1 "$exe" "$@"
xargs -0rt "$exe" "$@"
echo
echo
elif [ "$all_required" -eq 0 ]; then
echo "Warning: $exe not found... skipping some tests."
else
13 changes: 13 additions & 0 deletions .ci-scripts/tests/test-sdk-e2e.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#! /bin/bash

set -e -o pipefail

KUBECONFIG="${KUBECONFIG:-${HOME}/.kube/config}"
SCRIPT_DIR="$(dirname "$(realpath "$0")")"
TOP="$(realpath "${SCRIPT_DIR}/../..")"

# https://github.com/operator-framework/operator-sdk/blob/master/doc/test-framework/writing-e2e-tests.md#running-go-test-directly-not-recommended
# Run the e2e, but not using the operator-sdk binary. This requires ensuring flags are correctly set.
# See https://github.com/operator-framework/operator-sdk/blob/master/pkg/test/framework.go for flags.
# operator-sdk test local --go-test-flags="-v -parallel=100" "./test/e2e"
go test "${TOP}/test/e2e/..." -root="${TOP}" -kubeconfig="${KUBECONFIG}" -globalMan /dev/null -namespacedMan /dev/null -v -parallel=100
99 changes: 0 additions & 99 deletions .ci-scripts/tests/test-simple-schedule.sh

This file was deleted.

2 changes: 2 additions & 0 deletions .ci-scripts/yamlconfig.yaml
Original file line number Diff line number Diff line change
@@ -8,11 +8,13 @@ rules:
document-start:
ignore: |
deploy/crds/snapscheduler.backube_snapshotschedules_crd.yaml
deploy/olm-catalog/snapscheduler/1.1.0/snapshotschedules.snapscheduler.backube.crd.yaml
helm/snapscheduler/crds/snapscheduler.backube_snapshotschedules_crd.yaml
indentation:
indent-sequences: consistent
line-length:
allow-non-breakable-inline-mappings: true
ignore: |
deploy/crds/snapscheduler.backube_snapshotschedules_crd.yaml
deploy/olm-catalog/snapscheduler/1.1.0/snapshotschedules.snapscheduler.backube.crd.yaml
helm/snapscheduler/crds/snapscheduler.backube_snapshotschedules_crd.yaml
16 changes: 8 additions & 8 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -10,10 +10,10 @@ on: # yamllint disable-line rule:truthy

env:
GO_VERSION: "1.13"
HELM_VERSION: "3.0.2"
HELM_VERSION: "3.2.0"
KIND_VERSION: "0.7.0"
OPERATOR_SDK_VERSION: "0.15.1"
GOLANGCI_VERSION: "1.23.3"
GOLANGCI_VERSION: "1.25.0"
GO111MODULE: "on"
IMAGE: "quay.io/backube/snapscheduler"

@@ -24,7 +24,7 @@ jobs:

steps:
- name: Checkout source
uses: actions/checkout@v1
uses: actions/checkout@v2

- name: Install prereqs
run: |
@@ -43,7 +43,7 @@ jobs:

steps:
- name: Checkout source
uses: actions/checkout@v1
uses: actions/checkout@v2

- name: Install Go
uses: actions/setup-go@v1
@@ -106,15 +106,15 @@ jobs:
matrix:
# There must be kindest/node images for these versions
# See: https://hub.docker.com/r/kindest/node/tags?page=1&ordering=name
KUBERNETES_VERSIONS: ["1.13.12", "1.14.10", "1.15.7", "1.16.4", "1.17.0"]
KUBERNETES_VERSIONS: ["1.13.12", "1.14.10", "1.15.7", "1.16.4", "1.17.0", "1.18.0"]

env:
KUBECONFIG: /tmp/kubeconfig
KUBERNETES_VERSION: ${{ matrix.KUBERNETES_VERSIONS }}

steps:
- name: Checkout source
uses: actions/checkout@v1
uses: actions/checkout@v2

- name: Install Helm
run: |
@@ -162,8 +162,8 @@ jobs:
- name: Verify snapscheduler is running
run: kubectl -n backube-snapscheduler wait --for condition=Available --timeout 60s deploy/snapscheduler

- name: Verify snapshot scheduling
run: ./.ci-scripts/tests/test-simple-schedule.sh
- name: Run e2e tests
run: ./.ci-scripts/tests/test-sdk-e2e.sh

push:
name: Push container to registry
11 changes: 9 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -7,7 +7,13 @@ This project follows [Semantic Versioning](https://semver.org/)

## [Unreleased]

## [1.1.0] - 2019-02-13
## [1.1.1] - 2020-04-24

### Fixed

- Fix crash when snapshotTemplate is not defined in schedule

## [1.1.0] - 2020-02-13

### Added

@@ -21,6 +27,7 @@ This project follows [Semantic Versioning](https://semver.org/)
- Label selectors to control which PVCs are selected for snapshotting
- Retention policies based on snapshot age or count

[unreleased]: https://github.com/backube/snapscheduler/compare/v1.1.0...HEAD
[unreleased]: https://github.com/backube/snapscheduler/compare/v1.1.1...HEAD
[1.1.1]: https://github.com/backube/snapscheduler/compare/v1.1.0...v1.1.1
[1.1.0]: https://github.com/backube/snapscheduler/compare/v1.0.0...v1.1.0
[1.0.0]: https://github.com/backube/snapscheduler/releases/tag/v1.0.0
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Container image to build
IMAGE := quay.io/backube/snapscheduler
# Version of golangci-lint to install (if asked)
GOLANGCI_VERSION := v1.23.3
GOLANGCI_VERSION := v1.25.0
# Version of operator-sdk to install (if asked)
OPERATOR_SDK_VERSION := v0.15.1
GOBINDIR := $(shell go env GOPATH)/bin
@@ -65,4 +65,4 @@ codecov: coverage.txt
curl -fL https://codecov.io/bash | bash -s

coverage.txt: generate
go test -covermode=atomic -coverprofile=coverage.txt ./...
go test -covermode=atomic -coverprofile=coverage.txt $(shell go list ./... | grep -v /test/e2e)
2 changes: 0 additions & 2 deletions deploy/crds/snapscheduler.backube_v1_snapshotschedule_cr.yaml
Original file line number Diff line number Diff line change
@@ -9,5 +9,3 @@ spec:
# schedule fields: min hr dom mo dow
# also supports @shortcuts
schedule: "@daily"
snapshotTemplate:
snapshotClassName: ebs-csi
6 changes: 6 additions & 0 deletions deploy/olm-catalog/csv-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
crd-cr-paths:
- deploy/crds
operator-path: deploy/operator.yaml
role-paths:
- deploy/role.yaml

Large diffs are not rendered by default.

Loading

0 comments on commit 143318d

Please sign in to comment.