-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci(upgrade): break down upgrade workflows
This PR breaks down the earlier upgrade CI workflow into 3 different workflows: 1. upgrade tests from last release to main 2. upgrade tests from older releases to last release 3. integration2 tests workflow We have added an env variable DGRAPH_UPGRADE_MAIN_ONLY so that we can identify what tests to run. This also updates the upgrade tests config to run tests with InPlace upgrade strategy as well.
- Loading branch information
1 parent
ee7f325
commit d47b064
Showing
8 changed files
with
152 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
name: ci-dgraph-integration2-tests | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- 'release/**' | ||
pull_request: | ||
types: | ||
- opened | ||
- reopened | ||
- synchronize | ||
- ready_for_review | ||
branches: | ||
- main | ||
- 'release/**' | ||
schedule: | ||
- cron: "0 */4 * * *" # every 4hrs | ||
jobs: | ||
dgraph-integration2-tests: | ||
if: github.event.pull_request.draft == false | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Get Go Version | ||
run: | | ||
#!/bin/bash | ||
GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) | ||
echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV | ||
- name: Set up Go | ||
uses: actions/setup-go@v3 | ||
with: | ||
go-version: ${{ env.GOVERSION }} | ||
- name: Make Linux Build and Docker Image | ||
run: make docker-image | ||
- name: Clean Up Environment | ||
run: | | ||
#!/bin/bash | ||
# clean cache | ||
go clean -testcache | ||
- name: Run Integration2 Tests | ||
run: | | ||
#!/bin/bash | ||
# go env settings | ||
export GOPATH=~/go | ||
# move the binary | ||
cp dgraph/dgraph ~/go/bin/dgraph | ||
# run the tests | ||
go test -v -timeout=30m -failfast -tags=integration2 ./... | ||
# clean up docker containers after test execution | ||
go clean -testcache | ||
# sleep | ||
sleep 5 |
40 changes: 40 additions & 0 deletions
40
.github/workflows/ci-dgraph-upgrade-fixed-versions-tests.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: ci-dgraph-upgrade-fixed-versions-tests | ||
on: | ||
schedule: | ||
- cron: "0 */12 * * *" # every 12hrs | ||
jobs: | ||
dgraph-upgrade-fixed-versions-tests: | ||
runs-on: [self-hosted, x64] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Get Go Version | ||
run: | | ||
#!/bin/bash | ||
GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) | ||
echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV | ||
- name: Set up Go | ||
uses: actions/setup-go@v3 | ||
with: | ||
go-version: ${{ env.GOVERSION }} | ||
- name: Make Linux Build and Docker Image | ||
run: make docker-image | ||
- name: Clean Up Environment | ||
run: | | ||
#!/bin/bash | ||
# clean cache | ||
go clean -testcache | ||
- name: Run Upgrade and Integration Tests | ||
run: | | ||
#!/bin/bash | ||
# go env settings | ||
export GOPATH=~/go | ||
# move the binary | ||
cp dgraph/dgraph ~/go/bin/dgraph | ||
# run the tests | ||
go test -v -timeout=4h -failfast -tags=upgrade ./... | ||
# clean up docker containers after test execution | ||
go clean -testcache | ||
# sleep | ||
sleep 5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters