Skip to content

updating code to qa branch from staging in order to achieve stabilisation in network #658

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 161 commits into from
Apr 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
161 commits
Select commit Hold shift + click to select a range
06f1419
:bug: Refresh allocation on change in owner (#342)
Sriep Sep 15, 2021
24ad186
object_operation_handler unit test (#335)
Sriep Sep 15, 2021
512e3ff
ChunkedUpload feature (#344)
cnlangzi Sep 23, 2021
6672504
added codeql-analysis (#347)
cnlangzi Sep 23, 2021
2e6e118
Fix/clean GitHub action (#348)
cnlangzi Sep 23, 2021
f57d576
Fix/GitHub action checkout (#352)
cnlangzi Sep 23, 2021
463477b
Create dependabot.yml (#359)
kushthedude Sep 25, 2021
d64e20b
Fix/rate limit crash (#370)
cnlangzi Sep 25, 2021
b4966e7
fix(dev): fixed cli
cnlangzi Oct 1, 2021
2e4157d
respond with certain level if level is present (#373)
lpoli Oct 1, 2021
eda3e63
chore(deps): bump go.uber.org/zap from 1.19.0 to 1.19.1 (#360)
dependabot[bot] Oct 1, 2021
4a1102a
chore(deps): bump github.com/mitchellh/mapstructure from 1.3.1 to 1.4…
dependabot[bot] Oct 1, 2021
723f238
chore(deps): bump github.com/spf13/viper from 1.7.0 to 1.9.0 (#361)
dependabot[bot] Oct 1, 2021
1534da6
Fix/gorm (#376)
cnlangzi Oct 2, 2021
ef0aadd
chore(deps): bump google.golang.org/grpc from 1.36.0 to 1.41.0 (#364)
dependabot[bot] Oct 2, 2021
991fb1c
chore(deps): bump github.com/improbable-eng/grpc-web (#366)
dependabot[bot] Oct 2, 2021
3eacee9
chore(deps): bump github.com/grpc-ecosystem/grpc-gateway/v2 (#368)
dependabot[bot] Oct 2, 2021
67ae37d
added backup job
anish-squareops Oct 6, 2021
ab56e7f
backup (#383)
anish-squareops Oct 8, 2021
9692b00
Update and rename build.yml to build-&-publish-docker-image
m-s-a-c Oct 13, 2021
0c5de39
chore(deps): bump gorm.io/gorm from 1.21.15 to 1.21.16 (#384)
dependabot[bot] Oct 14, 2021
16ffc02
fix(copy):0chain/zboxcli:115 fixed hash issue on copy (#387)
cnlangzi Oct 15, 2021
ef1b86d
:bug: Error sharing files with wrong clientID (#392)
moldis Oct 20, 2021
97771a8
fix(docs):build.blobber.sh has been split into 3 files (#396)
cnlangzi Oct 20, 2021
fd25924
Fix/challenge log (#400)
cnlangzi Oct 25, 2021
d394619
Fixed a Typo error in README.md file (#402)
VishwajeetT22 Oct 27, 2021
fd4e313
Update backup gitaction for condition check.
m-s-a-c Oct 27, 2021
638ddd0
Commit date correction in backup.yml
m-s-a-c Oct 28, 2021
3a98060
fix(docker):# fixed alpine mirros issue (#414)
cnlangzi Oct 28, 2021
f26e15c
blobber readme changes (#410)
hm90121 Oct 28, 2021
2471dcf
fix(git): fixed conflict
cnlangzi Oct 29, 2021
c43f562
chore(deps): bump gorm.io/driver/postgres from 1.1.2 to 1.2.1 (#411)
dependabot[bot] Oct 29, 2021
f429b35
chore(deps): bump gorm.io/gorm from 1.21.16 to 1.22.2 (#412)
dependabot[bot] Oct 29, 2021
cd2a306
Fixed missing build tag in dockerized images (#415)
iamrz1 Oct 31, 2021
7f02d77
add CGO_ENABLED=1 to the unit test (#418)
Nov 4, 2021
a82e06f
:bug: Root folder sharing not allowing to dig inside 2nd layer subfol…
moldis Nov 5, 2021
9347bb2
:bug: Fixing issue with Encrypted Files (#409)
moldis Nov 5, 2021
591bdf4
chore(deps): bump github.com/improbable-eng/grpc-web (#419)
dependabot[bot] Nov 7, 2021
c5f2960
chore(deps): bump google.golang.org/grpc from 1.41.0 to 1.42.0 (#416)
dependabot[bot] Nov 7, 2021
6e76d29
Update build-&-publish-docker-image.yml
anish-squareops Nov 8, 2021
046d4e6
Signature verification in file meta api to ensure authorized access t…
iamrz1 Nov 9, 2021
66b6c21
fix: rollback to herumi bls (#425)
cnlangzi Nov 10, 2021
735f783
add system tests workflow
stewartie4 Nov 10, 2021
76098ab
refactor(main):improved startup code (#424)
cnlangzi Nov 11, 2021
73c141c
start grpc server in background (#428)
cnlangzi Nov 11, 2021
5b0a7dd
move herumi installation to base image and use it to the entire docke…
Nov 12, 2021
765ecb5
fix(devops): fixed git clone with checkout@v1
cnlangzi Nov 12, 2021
8a4661d
fix(devops):merged dockerize.yml into build-&-publish-docker-image.yml
cnlangzi Nov 12, 2021
7ff2986
fix(devops):merged ci.yml into tests.yml
cnlangzi Nov 12, 2021
116d592
fix(devops):added multiple mirrors for apline package repositories
cnlangzi Nov 12, 2021
912f094
fix script for linux build (#433)
Nov 15, 2021
d947df0
Fix/integration tests GitHub (#429)
cnlangzi Nov 15, 2021
6432684
chore(deps): bump gorm.io/gorm from 1.22.2 to 1.22.3 (#434)
dependabot[bot] Nov 15, 2021
523d8dc
chore(deps): bump gorm.io/driver/postgres from 1.2.1 to 1.2.2 (#430)
dependabot[bot] Nov 15, 2021
4a93e80
Expanding unit-tests && fixing issue with renaming dirs (#386)
moldis Nov 16, 2021
cd08727
issue 420: override "{}" when 'latest_redeemed_rm' is empty string. (…
princeparmar Nov 16, 2021
3dd0b3d
Trigger system tests from blobber PR (#427)
stewartie4 Nov 16, 2021
8fa8e72
:bug: Reject rename if file already exists (#390)
moldis Nov 17, 2021
7de518e
fix zbox list-all wrong return, and make error format clearer (#435)
Nov 17, 2021
6f02cdd
Update/gosdk (#436)
Nov 18, 2021
97aaef4
fix wrong error output and remove readonly check for storage hander (…
Nov 19, 2021
dc5c2dc
fix substitution bug
stewartie4 Nov 21, 2021
40fa394
fix(devops):fixed docker image tag
cnlangzi Nov 23, 2021
7d4af78
fix(devops):fixed docker image tag
cnlangzi Nov 23, 2021
8cea1cf
[Feature] Improved stats page (#431)
iamrz1 Nov 29, 2021
e9ad91e
in case of listing for newallocation (#447)
princeparmar Dec 1, 2021
500fd52
Create dir logic added if given path is not available. (#446)
princeparmar Dec 4, 2021
2cd899d
Feature/use system tests action (#456)
stewartie4 Dec 6, 2021
15777e3
feat(wasmsdk):0chain/gosdk#294 fixed cors on blobber hanlders (#457)
cnlangzi Dec 7, 2021
27b1eda
fix cors and max_file_size checking (#458)
cnlangzi Dec 8, 2021
d033a32
Remove max_file_size restriction (#460)
lpoli Dec 9, 2021
9b375a5
ignore token that never expired (has 0 value) (#461)
Dec 10, 2021
1d86b6a
Feature/use system tests action (#463)
stewartie4 Dec 11, 2021
82d9f6b
Update PR template and typo fixes (#466)
stewartie4 Dec 13, 2021
9631e8f
checkout current branch explicitly on manual system tests
stewartie4 Dec 16, 2021
8866d99
checkout current branch explicitly on manual system tests (#469)
stewartie4 Dec 17, 2021
e30ded3
Fix stats error for non-html endpoints (#475)
iamrz1 Dec 28, 2021
9abf9e1
Bug/issue 401 copy file when no dir (#464)
princeparmar Dec 29, 2021
1dc97c9
notify all PRs on manual system tests (#478)
stewartie4 Dec 30, 2021
2427b6f
fix(gosdk): upgraded gosdk with 20211230004341-97405e30f6ea (#481)
cnlangzi Dec 30, 2021
f2e2c36
fix(gomod): upgraded deps (#489)
cnlangzi Dec 31, 2021
30916c0
handling for delete root (#453)
princeparmar Dec 31, 2021
7994cb4
Bug/issue 401 copy file when no dir (#490)
princeparmar Dec 31, 2021
334f1c5
collaborators added in list api (#452)
princeparmar Jan 2, 2022
2490ac1
Get Refs with Authticket (#495)
lpoli Jan 14, 2022
178e93f
https flags added in blobber server. (#500)
princeparmar Jan 14, 2022
9213cb2
fix(gomod): upgrade gosdk, gorm and zap (#501)
cnlangzi Jan 14, 2022
112c4bd
removed physical createdir, updated createdir default size. (#491)
princeparmar Jan 17, 2022
a8d54da
readme updated for https. (#505)
princeparmar Jan 20, 2022
741e999
fix(main): register with https on zcn (#510)
cnlangzi Jan 20, 2022
4ecc324
fix(gomod):upgraded grpc packages (#512)
cnlangzi Jan 21, 2022
3e5b77a
fix(node): added cli argument --hosturl to register url on zcn (#513)
cnlangzi Jan 23, 2022
caf05c9
fix(upload): thumbnail is lost (#516)
cnlangzi Jan 26, 2022
e8bb202
fix(hash): updated sha1 with sha256 for file hash (#515)
cnlangzi Jan 28, 2022
6daf972
Put spread out sql in one place (#519)
lpoli Jan 31, 2022
6041fff
Fix issue raised by linter (#520)
lpoli Feb 3, 2022
557ee87
Optimize/verify auth ticket function (#525)
lpoli Feb 4, 2022
60edfee
Fix/public share issue (#528)
lpoli Feb 5, 2022
629a907
Allow collaborators to provide share to other clients (#531)
lpoli Feb 8, 2022
743d0d4
write-marker for copied files. (#492)
princeparmar Feb 10, 2022
73e5db1
Optimize/download (#526)
lpoli Feb 10, 2022
22e6132
fix(merkle): fixed merkle chunk size for challenge hash (#533)
cnlangzi Feb 11, 2022
a2465dd
fix(download): fixed encryption header issues (#536)
cnlangzi Feb 13, 2022
f76a6f3
Fix/reduce encryption header size (#538)
cnlangzi Feb 15, 2022
4a9422a
Feat/db auto migrate (#539)
cnlangzi Feb 17, 2022
372e64b
download migrated from post to get (#540)
princeparmar Feb 17, 2022
2479a8c
fix(writemarker): added distributed locks for WM (#546)
cnlangzi Feb 22, 2022
1449981
delete file query update. (#542)
princeparmar Feb 22, 2022
3674590
Update PR template (#553)
Kishan-Dhakan Feb 25, 2022
88ba0c5
change data reading from form to header for download. (#550)
princeparmar Feb 27, 2022
cbfef77
change statucode for delete file when file not found. (#551)
princeparmar Feb 28, 2022
b468fa9
Update PULL_REQUEST_TEMPLATE.md (#560)
cnlangzi Mar 1, 2022
73f9b73
fix/updated WriteMarkerMutex (#555)
cnlangzi Mar 2, 2022
8ff5a54
Feature/99 statuscode 204 for file not found (#559)
princeparmar Mar 2, 2022
03d61ae
Feat/hashnode API (#558)
cnlangzi Mar 2, 2022
aef63d1
skip minio setup if minio.start is false in config. (#564)
princeparmar Mar 2, 2022
f969d5e
fix(devops): enabled build job for tag (#566)
cnlangzi Mar 5, 2022
0d4a61a
fix(gomod): upgraded gprc-gateway with v2.8.0 (#567)
cnlangzi Mar 5, 2022
7602616
fix(writelock):release lock if file is committed (#570)
cnlangzi Mar 5, 2022
9e894f5
fix(devops): build multi platform images (#568)
cnlangzi Mar 6, 2022
a895c78
fix(challenge): removed unused lock on challenge worker (#574)
cnlangzi Mar 9, 2022
90f324c
Fix file upload inside file (#578)
lpoli Mar 10, 2022
b6e90ed
fix(docker): fixed validator workdir issue (#581)
cnlangzi Mar 10, 2022
c1c3e70
fix(gomod): upgraded grpc (#580)
cnlangzi Mar 11, 2022
3d825c8
fix(resty): upgraded gosdk for restry (#576)
cnlangzi Mar 12, 2022
9a39536
fix(devops): enabled workflow_dispatch on dockerize job (#587)
cnlangzi Mar 15, 2022
4b23232
fix(copy):fixed panicking issue and missing stats bug (#584)
cnlangzi Mar 16, 2022
f54ed59
fix(gomod): upgraded testify (#593)
cnlangzi Mar 16, 2022
ce1870a
fix(init): try ping postgres to check if it is ready (#586)
cnlangzi Mar 17, 2022
c6be906
fix(challenge):db conn is not closed (#591)
cnlangzi Mar 17, 2022
87e7ca5
fix(download):fixed Access-Control-Allow-Headers for wasm sdk (#595)
cnlangzi Mar 17, 2022
d4cf005
fix(gomod):upgraded gorm and grpc (#599)
cnlangzi Mar 23, 2022
2562e81
Feat/available after (#600)
cnlangzi Mar 24, 2022
c8f9979
Feat/batch chunks upload (#603)
cnlangzi Mar 26, 2022
df3682e
Modify/read marker2 (#582)
lpoli Mar 27, 2022
e495e92
:hammer: init commit
moldis Mar 28, 2022
88de63d
:art: linting
moldis Mar 28, 2022
760a634
fix(createdir):improved it as idempotent (#604)
cnlangzi Mar 29, 2022
92b218c
fix(devops):upload coverage to Codecov (#614)
cnlangzi Mar 30, 2022
7777736
fix(getobjecttree): getobjecttree should work even allocation is empt…
cnlangzi Mar 31, 2022
2834dec
fix(collaborator):updated permission checking on file upload/update/d…
cnlangzi Mar 31, 2022
0b8f670
fix(devops):fixed incorrect url for codecov status badge (#616)
cnlangzi Mar 31, 2022
003184d
Update build-&-publish-docker-image.yml (#608)
Kishan-Dhakan Mar 31, 2022
d14a32f
Created config_change_alert.yaml (#617)
vinayakgautamops Apr 1, 2022
1075eb2
Update gosdk to add 'state_changes_count' (#609)
peterlimg Apr 2, 2022
e35c51f
Update system_tests.yml (#619)
Kishan-Dhakan Apr 4, 2022
957852a
Issue 524 (#529)
abouroumine Apr 4, 2022
48b95da
Sa optimise (#623)
ssardana96 Apr 7, 2022
d2c3392
Feat/partial delete suppport (#626)
cnlangzi Apr 9, 2022
aad9ea2
fix(gosdk): upgraded gorm (#629)
cnlangzi Apr 12, 2022
09d604a
feat(devops): automatically upgrade gosdk (#633)
cnlangzi Apr 12, 2022
07f0982
Remove unused param (#634)
Kishan-Dhakan Apr 12, 2022
b3a7f62
add new filter param + new runners (#638)
stewartie4 Apr 15, 2022
9d6fe7b
Enhancement/db automigration2 (#615)
lpoli Apr 16, 2022
c817165
Skip gorm inserting values to sequence field (#645)
lpoli Apr 21, 2022
4b11189
Fix/revert to readcounter (#632)
lpoli Apr 23, 2022
d2112ac
fix integration tests for docker.local (#654)
rrrooommmaaa Apr 25, 2022
ad877da
fix(writemarker):improved ReddemWriteMarkers to fix #624 (#647)
cnlangzi Apr 25, 2022
132f070
Fix/blobber reg (#643)
cnlangzi Apr 25, 2022
922ea95
fix(stats):fixed panicking issue on loadAllocReadmarkersStat for #644…
cnlangzi Apr 25, 2022
4f1c80e
Update config_change_alert.yaml (#650)
vinayakgautamops Apr 25, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "gomod" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "daily"
open-pull-requests-limit: 10
reviewers:
- cnlangzi
labels:
- pr/dependencies
45 changes: 45 additions & 0 deletions .github/workflows/backup.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Mirror repo to S3

on:
schedule:
# Runs everyday at 12:25 am
- cron: '25 0 * * * '
workflow_dispatch:

jobs:
s3Backup:
runs-on: docker-builds
steps:
- uses: actions/checkout@v1

- name: Get info
id: get_info
run: |
GIT_COMMIT_DATE="$((`git log -n 1 --date-order --all | grep Date | awk '{ print $4 }'`))"
YESTERDAY_DATE="$((`date | awk '{ print $3 }'`-1))"
echo ::set-output name=GIT_COMMIT_DATE::${GIT_COMMIT_DATE}
echo ::set-output name=YESTERDAY_DATE::${YESTERDAY_DATE}
echo $GIT_COMMIT_DATE
echo $YESTERDAY_DATE

- name: Create backup
if: steps.get_info.outputs.GIT_COMMIT_DATE == steps.get_info.outputs.YESTERDAY_DATE
run: |
github-backup 0chain -P -t ${{ secrets.ACCESS_TOKEN }} --output-directory=/github-backup/blobber --all -O -R blobber

- name: Create zip
if: steps.get_info.outputs.GIT_COMMIT_DATE == steps.get_info.outputs.YESTERDAY_DATE
run: zip -r blobber.zip /github-backup/blobber

- name: Set AWS credentials
if: steps.get_info.outputs.GIT_COMMIT_DATE == steps.get_info.outputs.YESTERDAY_DATE
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.SECRET_ACCESS_KEY }}
aws-region: us-east-2

- name: Backup to s3
if: steps.get_info.outputs.GIT_COMMIT_DATE == steps.get_info.outputs.YESTERDAY_DATE
run: |
aws s3 cp blobber.zip s3://${{ secrets.MIRROR_TARGET }}/blobber.zip
24 changes: 24 additions & 0 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Benchmark

concurrency:
group: "benchmark-${{ github.ref }}"
cancel-in-progress: true

on:
push:
branches: [ master, staging ]

jobs:
benchmark:
runs-on: [self-hosted, conductor-test]
steps:
- name: Setup go 1.17
uses: actions/setup-go@v2
with:
go-version: '1.17' # The Go version to download (if necessary) and use.

- name: Clone blobber
uses: actions/checkout@v2

- name: Run benchmark
run: CGO_ENABLED=1 go test -tags bn256 -benchmem -run="BenchmarkUploadFile*" -bench="BenchmarkUploadFile*" ./... | tee benchmark.txt
193 changes: 193 additions & 0 deletions .github/workflows/build-&-publish-docker-image.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,193 @@
name: "Dockerize"

concurrency:
group: "publish-${{ github.ref }}"
cancel-in-progress: true

on:
push:
branches:
- staging
tags:
- '*'
pull_request:
workflow_dispatch:

env:
BLOBBER_REGISTRY: ${{ secrets.BLOBBER_REGISTRY }}
VALIDATOR_REGISTRY: ${{ secrets.VALIDATOR_REGISTRY }}

jobs:
blobber:
runs-on: [self-hosted, build]
steps:
- name: Set docker image tag
run: |
if [[ "${{github.ref}}" == refs/pull/* ]]; then
tag=${GITHUB_REF/\/merge/}
echo "TAG=$(echo pr-${tag:10})" >> $GITHUB_ENV
else
echo "TAG=$(echo ${GITHUB_REF#refs/*/} | sed 's/\//-/g')" >> $GITHUB_ENV
fi

echo "BRANCH=$([ -z '${{ github.event.pull_request.head.sha }}' ] && echo ${GITHUB_REF#refs/*/} || echo $GITHUB_HEAD_REF)" >> $GITHUB_ENV
echo "SHA=$([ -z '${{ github.event.pull_request.head.sha }}' ] && echo $GITHUB_SHA || echo '${{ github.event.pull_request.head.sha }}')" >> $GITHUB_ENV

- name: Setup go 1.17
uses: actions/setup-go@v2
with:
go-version: '1.17' # The Go version to download (if necessary) and use.

- name: Clone blobber
uses: actions/checkout@v1

- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}

- name: Build base
run: |
export DOCKER_IMAGE_BASE="${BLOBBER_REGISTRY}:base"
export DOCKER_BUILD="buildx build --platform linux/amd64,linux/arm64 --push"
./docker.local/bin/build.base.sh

- name: Build blobber
run: |
SHORT_SHA=$(echo ${{ env.SHA }} | head -c 8)

export DOCKER_IMAGE_BASE="${BLOBBER_REGISTRY}:base"
export DOCKER_IMAGE_BLOBBER="-t ${BLOBBER_REGISTRY}:${TAG} -t ${BLOBBER_REGISTRY}:${TAG}-${SHORT_SHA}"
export DOCKER_BUILD="buildx build --platform linux/amd64,linux/arm64 --push"

./docker.local/bin/build.blobber.sh

validator:
runs-on: [self-hosted, build]
steps:
- name: Set docker image tag
run: |
if [[ "${{github.ref}}" == refs/pull/* ]]; then
tag=${GITHUB_REF/\/merge/}
echo "TAG=$(echo pr-${tag:10})" >> $GITHUB_ENV
else
echo "TAG=$(echo ${GITHUB_REF#refs/*/} | sed 's/\//-/g')" >> $GITHUB_ENV
fi

echo "BRANCH=$([ -z '${{ github.event.pull_request.head.sha }}' ] && echo ${GITHUB_REF#refs/*/} || echo $GITHUB_HEAD_REF)" >> $GITHUB_ENV
echo "SHA=$([ -z '${{ github.event.pull_request.head.sha }}' ] && echo $GITHUB_SHA || echo '${{ github.event.pull_request.head.sha }}')" >> $GITHUB_ENV

- name: Setup go 1.17
uses: actions/setup-go@v2
with:
go-version: '1.17' # The Go version to download (if necessary) and use.

- name: Clone blobber
uses: actions/checkout@v1

- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}

- name: Build base
run: |
export DOCKER_IMAGE_BASE="${VALIDATOR_REGISTRY}:base"
export DOCKER_BUILD="buildx build --platform linux/amd64,linux/arm64 --push"
./docker.local/bin/build.base.sh

- name: Build validator
run: |
SHORT_SHA=$(echo ${{ env.SHA }} | head -c 8)

export DOCKER_IMAGE_BASE="${VALIDATOR_REGISTRY}:base"
export DOCKER_IMAGE_VALIDATOR="-t ${VALIDATOR_REGISTRY}:${TAG} -t ${VALIDATOR_REGISTRY}:${TAG}-${SHORT_SHA}"
export DOCKER_BUILD="buildx build --platform linux/amd64,linux/arm64 --push"

./docker.local/bin/build.validator.sh


system-tests:
if: github.event_name != 'workflow_dispatch'
needs: [blobber, validator]
runs-on: [ tests-suite ]
steps:
- name: "Get current PR"
uses: jwalton/gh-find-current-pr@v1
id: findPr
with:
github-token: ${{ github.token }}

- name: "Set PR status as pending"
uses: niteoweb/[email protected]
if: steps.findPr.outputs.number
with:
pr_number: ${{ steps.findPr.outputs.pr }}
description: "System tests running with default config..."
state: "pending"
repository: ${{ github.repository }}
context: "0Chain System Tests"
target_url: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}
env:
GITHUB_TOKEN: ${{ github.token }}

- name: "Setup"
run: |
if [[ "${{github.ref}}" == refs/pull/* ]]; then
tag=${GITHUB_REF/\/merge/}
echo "TAG=$(echo pr-${tag:10})" >> $GITHUB_ENV
else
echo "TAG=$(echo ${GITHUB_REF#refs/*/} | sed 's/\//-/g')" >> $GITHUB_ENV
fi

echo "BRANCH=$([ -z '${{ github.event.pull_request.head.sha }}' ] && echo ${GITHUB_REF#refs/*/} || echo $GITHUB_HEAD_REF)" >> $GITHUB_ENV
echo "SHORT_SHA=$(([ -z '${{ github.event.pull_request.head.sha }}' ] && echo $GITHUB_SHA || echo '${{ github.event.pull_request.head.sha }}') | head -c 8)" >> $GITHUB_ENV
echo "NETWORK_URL=$(echo dev-${RUNNER_NAME:(-1)}.devnet-0chain.net)" >> $GITHUB_ENV
echo "RUNNER_NUMBER=${RUNNER_NAME:(-1)}" >> $GITHUB_ENV

- name: "Deploy 0Chain"
uses: 0chain/actions/deploy-0chain@master
with:
kube_config: ${{ secrets[format('DEV{0}KC', env.RUNNER_NUMBER)] }}
teardown_condition: "TESTS_PASSED"
miner_image: staging
sharder_image: staging
blobber_image: ${{ env.TAG }}-${{ env.SHORT_SHA }}
validator_image: ${{ env.TAG }}-${{ env.SHORT_SHA }}
zbox_image: staging
zblock_image: staging
zdns_image: staging
explorer_image: latest
zproxy_image: staging
zsearch_image: staging
zbox_cli_branch: staging
zwallet_cli_branch: staging
custom_go_sdk_version: staging

- name: "Run System tests"
uses: 0chain/actions/run-system-tests@master
with:
system_tests_branch: master
network: ${{ env.NETWORK_URL }}
zbox_cli_branch: staging
zwallet_cli_branch: staging
svc_account_secret: ${{ github.token }}
deploy_report_page: false
archive_results: true
run_flaky_tests: false
retry_failures: true

- name: "Set PR status as ${{ job.status }}"
if: ${{ (success() || failure()) && steps.findPr.outputs.number }}
uses: niteoweb/[email protected]
with:
pr_number: ${{ steps.findPr.outputs.pr }}
description: "System tests with default config ${{ job.status }}"
state: ${{ job.status }}
repository: ${{ github.repository }}
context: "0Chain System Tests"
target_url: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}
env:
GITHUB_TOKEN: ${{ github.token }}
95 changes: 0 additions & 95 deletions .github/workflows/build.yml

This file was deleted.

Loading