Skip to content

Commit 806264a

Browse files
authored
Merge pull request #737 from LIT-Protocol/feature/get-latest-commit-hash-for-shiva
Get latest commit hash for shiva in CI
2 parents 683a0d6 + e1e8ea8 commit 806264a

File tree

3 files changed

+60
-559
lines changed

3 files changed

+60
-559
lines changed

.github/workflows/ci.yml

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,20 +42,27 @@ jobs:
4242
integration-tests:
4343
runs-on: ubuntu-latest
4444
timeout-minutes: 30
45-
env:
46-
DATIL_COMMIT_HASH: ae3c20e07eb933b61073689b95f56867c03de252
4745
steps:
4846
- name: Checkout repo
4947
uses: actions/checkout@v2
5048
with:
5149
fetch-depth: 0
52-
- name: Checkout Lit Actions
50+
- name: Find latest datil commit hash for last successful "rust/lit-node-build-commit-hash" workflow in the Lit Assets repo
51+
uses: LIT-Protocol/last-successful-build-action@372ea3325a894558ee74d970217ca421ea562fba
52+
id: last-successful-build
53+
with:
54+
token: "${{ secrets.GH_PAT_FOR_SHIVA }}"
55+
branch: "datil"
56+
workflow: "rust/lit-node-build-commit-hash"
57+
repo: LIT-Protocol/lit-assets
58+
# this outputs to dollarSign{{ steps.last-successful-build.outputs.lastSuccessfulBuildSha }}
59+
- name: Checkout Lit Assets
5360
uses: actions/checkout@v4
5461
id: checkout
5562
with:
5663
fetch-depth: 0
5764
repository: LIT-Protocol/lit-assets
58-
ref: ${{env.DATIL_COMMIT_HASH}}
65+
ref: ${{ steps.last-successful-build.outputs.lastSuccessfulBuildSha }}
5966
token: ${{secrets.GH_PAT_FOR_SHIVA}}
6067
path: ${{ github.workspace }}/lit-assets/
6168
submodules: false
@@ -75,7 +82,7 @@ jobs:
7582
run: docker pull ghcr.io/lit-protocol/shiva:latest
7683
- name: Run Shiva Container
7784
id: shiva-runner
78-
run: docker run -d -m 32g -p 8000:8000 -p 8545:8545 -p 7470:7470 -p 7471:7471 -p 7472:7472 -p 7473:7473 -p 7474:7474 -p 7475:7475 -v ${{github.workspace}}/lit-assets:/data -e GH_PAT=${{secrets.GH_PAT_FOR_SHIVA}} -e HASH=$DATIL_COMMIT_HASH -e IPFS_API_KEY=${{secrets.IPFS_API_KEY}} --name shiva ghcr.io/lit-protocol/shiva:latest
85+
run: docker run -d -m 32g -p 8000:8000 -p 8545:8545 -p 7470:7470 -p 7471:7471 -p 7472:7472 -p 7473:7473 -p 7474:7474 -p 7475:7475 -v ${{github.workspace}}/lit-assets:/data -e GH_PAT=${{secrets.GH_PAT_FOR_SHIVA}} -e HASH=${{ steps.last-successful-build.outputs.lastSuccessfulBuildSha }} -e IPFS_API_KEY=${{secrets.IPFS_API_KEY}} --name shiva ghcr.io/lit-protocol/shiva:latest
7986
- name: Set up Node.js
8087
uses: actions/setup-node@v3
8188
with:

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,8 @@
7272
"uint8arrays": "^4.0.3"
7373
},
7474
"devDependencies": {
75-
"@nrwl/devkit": "19.6.3",
76-
"@nrwl/eslint-plugin-nx": "19.6.3",
77-
"@nx/esbuild": "^17.3.0",
75+
"@nx/devkit": "17.3.0",
76+
"@nx/esbuild": "17.3.0",
7877
"@nx/eslint-plugin": "17.3.0",
7978
"@nx/jest": "17.3.0",
8079
"@nx/js": "17.3.0",

0 commit comments

Comments
 (0)