Skip to content

Commit

Permalink
chore(CHANGELOG): add changelogs for v2.0.0 (openebs-archive#35)
Browse files Browse the repository at this point in the history
Along with Changelog updates, this commit fixes the travis
 - bumps the k8s version in minikube
 - updates the latest cstor operator
   yaml with new CRDs
 - improves error reporting by adding logs to tests

Signed-off-by: shubham <[email protected]>
  • Loading branch information
shubham14bajpai authored and kmova committed Aug 21, 2020
1 parent c290735 commit 449fcee
Show file tree
Hide file tree
Showing 12 changed files with 53 additions and 81 deletions.
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ addons:
update: true

install:
- sudo apt-get install -y conntrack
- if [ "$TRAVIS_BUILD_DIR" != "$GOPATH/src/github.com/openebs/upgrade" ]; then
mkdir -p $GOPATH/src/github.com/openebs/;
mv $TRAVIS_BUILD_DIR $GOPATH/src/github.com/openebs;
Expand All @@ -56,10 +57,10 @@ before_script: # TODO add golangci yaml config
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.25.0
- if [ "$TRAVIS_CPU_ARCH" == "amd64" ]; then
curl -Lo kubectl https://storage.googleapis.com/kubernetes-release/release/v1.18.1/bin/linux/amd64/kubectl && chmod +x kubectl && sudo mv kubectl /usr/local/bin/;
curl -Lo minikube https://storage.googleapis.com/minikube/releases/v1.8.1/minikube-linux-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/;
curl -Lo minikube https://storage.googleapis.com/minikube/releases/v1.12.3/minikube-linux-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/;
mkdir -p $HOME/.kube $HOME/.minikube;
touch $KUBECONFIG;
sudo minikube start --vm-driver=none --kubernetes-version=v1.16.0;
sudo minikube start --vm-driver=none --kubernetes-version=v1.18.0;
sudo chown -R travis /home/travis/.minikube/;
JSONPATH='{range .items[*]}{@.metadata.name}:{range @.status.conditions[*]}{@.type}={@.status};{end}{end}'; until kubectl get nodes -o jsonpath="$JSONPATH" 2>&1 | grep -q "Ready=True"; do sleep 1; done;
fi
Expand Down
27 changes: 27 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,32 @@
# Changelog

## [v2.0.0](https://github.com/openebs/upgrade/tree/v2.0.0) (2020-08-15)

**Merged pull requests:**

- fix\(migration\): fix striped raid group config while migrating [\#39](https://github.com/openebs/upgrade/pull/39) ([shubham14bajpai](https://github.com/shubham14bajpai))

## [v2.0.0-RC2](https://github.com/openebs/upgrade/tree/v2.0.0-RC2) (2020-08-14)

**Merged pull requests:**

- chore\(vendor\): update latest openebs/api vendor files [\#37](https://github.com/openebs/upgrade/pull/37) ([shubham14bajpai](https://github.com/shubham14bajpai))
- chore\(vendor\): update latest openebs/api vendor files [\#34](https://github.com/openebs/upgrade/pull/34) ([shubham14bajpai](https://github.com/shubham14bajpai))

## [v2.0.0-RC1](https://github.com/openebs/upgrade/tree/v2.0.0-RC1) (2020-08-05)

**Merged pull requests:**

- chore\(migrate\): add travis sanity test [\#29](https://github.com/openebs/upgrade/pull/29) ([shubham14bajpai](https://github.com/shubham14bajpai))
- chore\(docs\): add example yamls and docs for cstor upgrades/migration [\#7](https://github.com/openebs/upgrade/pull/7) ([shubham14bajpai](https://github.com/shubham14bajpai))

## [v1.12.1](https://github.com/openebs/upgrade/tree/v1.12.1) (2020-07-30)

**Merged pull requests:**

- fix\(version\): fix version checks of resources [\#28](https://github.com/openebs/upgrade/pull/28) ([shubham14bajpai](https://github.com/shubham14bajpai))


## [v1.12.0](https://github.com/openebs/upgrade/tree/v1.12.0) (2020-07-12)

**Merged pull requests:**
Expand Down
7 changes: 6 additions & 1 deletion ci/migrate/sanity.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ make migrate-image.amd64
# setup openebs & cstor v1 for migration
./ci/migrate/setup.sh || exit 1
# run migration tests
./ci/migrate/test.sh || exit 1
./ci/migrate/test.sh
if [[ $? != 0 ]]; then
kubectl logs --tail=50 -l job-name=migrate-pool -n openebs
kubectl logs --tail=50 -l job-name=migrate-volume -n openebs
exit 1
fi

rm ./ci/migrate/volume.yaml ./ci/migrate/application.yaml
3 changes: 1 addition & 2 deletions ci/migrate/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ kubectl wait --for=condition=Ready pod -l lkey=lvalue --timeout=600s

echo "Install cstor & csi operators"

kubectl apply -f https://raw.githubusercontent.com/openebs/charts/gh-pages/csi-operator-ubuntu-18.04.yaml \
-f https://raw.githubusercontent.com/openebs/charts/gh-pages/cstor-operator.yaml
kubectl apply -f https://raw.githubusercontent.com/openebs/charts/gh-pages/cstor-operator.yaml
sleep 5
kubectl wait --for=condition=available --timeout=600s deployment/cspc-operator -n openebs
4 changes: 2 additions & 2 deletions ci/migrate/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ echo "Migrating pool to cspc"

kubectl apply -f ./ci/migrate/pool.yaml
sleep 5
kubectl wait --for=condition=complete job/migrate-pool -n openebs --timeout=800s
kubectl wait --for=condition=complete job/migrate-pool -n openebs --timeout=550s
kubectl logs --tail=50 -l job-name=migrate-pool -n openebs

echo "Migrating extetnal volume to csi volume"
Expand All @@ -22,7 +22,7 @@ pvname=$(kubectl get pvc testclaim-busybox-0 -o jsonpath="{.spec.volumeName}")
sed "s/PVNAME/$pvname/" ./ci/migrate/volume.tmp.yaml > ./ci/migrate/volume.yaml
kubectl apply -f ./ci/migrate/volume.yaml
sleep 5
kubectl wait --for=condition=complete job/migrate-volume -n openebs --timeout=800s
kubectl wait --for=condition=complete job/migrate-volume -n openebs --timeout=550s
kubectl logs --tail=50 -l job-name=migrate-volume -n openebs

echo "Scaling up application after migration"
Expand Down
2 changes: 1 addition & 1 deletion ci/migrate/volume.tmp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
name: migrate-volume
namespace: openebs
spec:
backoffLimit: 4
backoffLimit: 0
template:
spec:
#VERIFY the value of serviceAccountName is pointing to service account
Expand Down
2 changes: 1 addition & 1 deletion ci/upgrade/pool.tmp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ metadata:
# The above command should return status of the openebs-apiserver.
namespace: openebs
spec:
backoffLimit: 4
backoffLimit: 0
template:
spec:
# VERIFY the value of serviceAccountName is pointing to service account
Expand Down
65 changes: 0 additions & 65 deletions ci/upgrade/pool.yaml

This file was deleted.

7 changes: 6 additions & 1 deletion ci/upgrade/sanity.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ export TEST_VERSION=${TEST_VERSION#v}
# setup openebs & cstor v1 for migration
./ci/upgrade/setup.sh || exit 1
# run migration tests
./ci/upgrade/test.sh || exit 1
./ci/upgrade/test.sh
if [[ $? != 0 ]]; then
kubectl logs --tail=50 -l job-name=upgrade-pool -n openebs
kubectl logs --tail=50 -l job-name=upgrade-volume -n openebs
exit 1
fi

rm ./ci/upgrade/volume.yaml ./ci/upgrade/application.yaml
6 changes: 3 additions & 3 deletions ci/upgrade/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ sleep 100

echo "Wait for cspc-operator to start"

kubectl wait --for=condition=available --timeout=600s deployment/cspc-operator -n openebs
kubectl wait --for=condition=available --timeout=300s deployment/cspc-operator -n openebs

echo "Create application with cStor volume on CSPC"

Expand All @@ -24,7 +24,7 @@ bdname=$(kubectl -n openebs get blockdevices -o jsonpath='{.items[*].metadata.na
sed "s|CSPCBD|$bdname|g" ./ci/upgrade/application.tmp.yaml | sed "s|NODENAME|$nodename|g" > ./ci/upgrade/application.yaml
kubectl apply -f ./ci/upgrade/application.yaml
sleep 10
kubectl wait --for=condition=available --timeout=600s deployment/percona
kubectl wait --for=condition=available --timeout=300s deployment/percona

echo "Upgrade control plane to latest version"

Expand All @@ -33,4 +33,4 @@ sed "s|testimage|$TEST_IMAGE_TAG|g" ./ci/upgrade/cstor-operator.tmp.yaml | sed "
kubectl apply -f https://raw.githubusercontent.com/openebs/cstor-operators/master/deploy/csi-operator.yaml \
-f ./ci/upgrade/cstor-operator.yaml
sleep 10
kubectl wait --for=condition=available --timeout=600s deployment/cspc-operator -n openebs
kubectl wait --for=condition=available --timeout=300s deployment/cspc-operator -n openebs
4 changes: 2 additions & 2 deletions ci/upgrade/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ echo "Upgrading CSPC pool"
sed "s|testimage|$TEST_IMAGE_TAG|g" ./ci/upgrade/pool.tmp.yaml | sed "s|testversion|$TEST_VERSION|g" > ./ci/upgrade/pool.yaml
kubectl apply -f ./ci/upgrade/pool.yaml
sleep 5
kubectl wait --for=condition=complete job/upgrade-pool -n openebs --timeout=800s
kubectl wait --for=condition=complete job/upgrade-pool -n openebs --timeout=550s
kubectl logs --tail=50 -l job-name=upgrade-pool -n openebs

echo "Upgrading CSI volume"
Expand All @@ -18,5 +18,5 @@ pvname=$(kubectl get pvc demo-csi-vol-claim -o jsonpath="{.spec.volumeName}")
sed "s|PVNAME|$pvname|g" ./ci/upgrade/volume.tmp.yaml | sed "s|testimage|$TEST_IMAGE_TAG|g" | sed "s|testversion|$TEST_VERSION|g" > ./ci/upgrade/volume.yaml
kubectl apply -f ./ci/upgrade/volume.yaml
sleep 5
kubectl wait --for=condition=complete job/upgrade-volume -n openebs --timeout=800s
kubectl wait --for=condition=complete job/upgrade-volume -n openebs --timeout=550s
kubectl logs --tail=50 -l job-name=upgrade-volume -n openebs
2 changes: 1 addition & 1 deletion ci/upgrade/volume.tmp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ metadata:
# The above command should return status of the openebs-apiserver.
namespace: openebs
spec:
backoffLimit: 4
backoffLimit: 0
template:
spec:
# VERIFY the value of serviceAccountName is pointing to service account
Expand Down

0 comments on commit 449fcee

Please sign in to comment.