|
1 | | -name: Build Docker Images |
2 | | - |
| 1 | +name: Build Packages |
3 | 2 | on: |
4 | 3 | push: |
5 | | - tags: |
6 | | - - '*' |
7 | | - workflow_dispatch: |
| 4 | + paths-ignore: |
| 5 | + - '**/README.md' |
| 6 | + |
| 7 | +concurrency: |
| 8 | + group: ${{ github.workflow }}-${{ github.ref }} |
| 9 | + cancel-in-progress: true |
8 | 10 |
|
9 | 11 | jobs: |
10 | | - build-eth-rpc-adapter: |
| 12 | + build: |
11 | 13 | runs-on: ubuntu-latest |
12 | 14 | steps: |
13 | 15 | - name: checkout |
14 | | - uses: actions/checkout@v3 |
15 | | - with: |
16 | | - submodules: 'recursive' |
17 | | - - name: Set up Docker Buildx |
18 | | - uses: docker/setup-buildx-action@v2 |
| 16 | + uses: actions/checkout@v4 |
19 | 17 |
|
20 | | - - name: Login to Docker Hub |
21 | | - uses: docker/login-action@v2 |
| 18 | + - name: setup node |
| 19 | + uses: actions/setup-node@v4 |
22 | 20 | with: |
23 | | - username: ${{ secrets.DOCKERHUB_USERNAME }} |
24 | | - password: ${{ secrets.DOCKERHUB_TOKEN }} |
| 21 | + node-version: 20 |
25 | 22 |
|
26 | | - - name: Docker meta |
27 | | - id: meta |
28 | | - uses: docker/metadata-action@v4 |
29 | | - with: |
30 | | - images: acala/eth-rpc-adapter |
31 | | - tags: | |
32 | | - type=semver,pattern={{version}} |
33 | | - type=raw,value={{sha}} |
34 | | - type=ref,event=branch |
| 23 | + - name: setup yarn |
| 24 | + run: npm install -g yarn |
35 | 25 |
|
36 | | - - name: Build and push |
37 | | - uses: docker/build-push-action@v4 |
38 | | - with: |
39 | | - context: . |
40 | | - file: packages/eth-rpc-adapter/Dockerfile |
41 | | - platforms: linux/amd64,linux/arm64 |
42 | | - push: true |
43 | | - tags: ${{ steps.meta.outputs.tags }} |
44 | | - labels: ${{ steps.meta.outputs.labels }} |
| 26 | + - name: install deps |
| 27 | + run: yarn install --immutable |
45 | 28 |
|
46 | | - build-evm-subql: |
47 | | - runs-on: ubuntu-latest |
48 | | - steps: |
49 | | - - name: checkout |
50 | | - uses: actions/checkout@v3 |
51 | | - with: |
52 | | - submodules: 'recursive' |
53 | | - - name: Set up Docker Buildx |
54 | | - uses: docker/setup-buildx-action@v2 |
55 | | - |
56 | | - - name: Login to Docker Hub |
57 | | - uses: docker/login-action@v2 |
58 | | - with: |
59 | | - username: ${{ secrets.DOCKERHUB_USERNAME }} |
60 | | - password: ${{ secrets.DOCKERHUB_TOKEN }} |
61 | | - |
62 | | - - name: Docker meta |
63 | | - id: meta |
64 | | - uses: docker/metadata-action@v4 |
65 | | - with: |
66 | | - images: acala/evm-subql |
67 | | - tags: | |
68 | | - type=semver,pattern={{version}} |
69 | | - type=raw,value={{sha}} |
70 | | - type=ref,event=branch |
71 | | -
|
72 | | - - name: Build and push |
73 | | - uses: docker/build-push-action@v4 |
74 | | - with: |
75 | | - context: . |
76 | | - file: packages/evm-subql/Dockerfile |
77 | | - platforms: linux/amd64,linux/arm64 |
78 | | - push: true |
79 | | - tags: ${{ steps.meta.outputs.tags }} |
80 | | - labels: ${{ steps.meta.outputs.labels }} |
| 29 | + - name: build |
| 30 | + run: yarn build |
0 commit comments