Skip to content

Commit 20e1a07

Browse files
committed
update github action workflows
1 parent e677f1c commit 20e1a07

File tree

4 files changed

+41
-6
lines changed

4 files changed

+41
-6
lines changed

.github/workflows/webpack.yml renamed to .github/workflows/client-webpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ on:
1212
workflow_dispatch:
1313

1414
jobs:
15-
build:
15+
client-webpack:
1616
runs-on: ubuntu-22.04
1717

1818
strategy:

.github/workflows/release.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,15 @@ on:
99

1010

1111
jobs:
12-
build:
13-
uses: ./.github/workflows/webpack.yml
12+
build-client-webpack:
13+
uses: ./.github/workflows/client-webpack.yml
1414

15-
release:
16-
runs-on: ubuntu-22.04
15+
build-server-image:
16+
uses: ./.github/workflows/server-image.yml
1717

18-
needs: build
18+
release:
19+
needs: [build-client-webpack, build-server-image]
20+
runs-on: ubuntu-latest
1921

2022
steps:
2123
- uses: actions/checkout@v4

.github/workflows/server-image.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Build and push back-end server Docker image
2+
3+
on:
4+
workflow_call:
5+
workflow_dispatch:
6+
7+
env:
8+
REGISTRY: ghcr.io
9+
IMAGE_NAME: ${{ github.repository }}-server
10+
11+
jobs:
12+
server-image:
13+
runs-on: ubuntu-latest
14+
permissions:
15+
contents: write
16+
packages: write
17+
18+
steps:
19+
- uses: actions/checkout@v4
20+
21+
- name: Log in to Container registry
22+
uses: docker/login-action@49ed152c8eca782a232dede0303416e8f356c37b # v2.0.0
23+
with:
24+
registry: ${{ env.REGISTRY }}
25+
username: ${{ github.actor }}
26+
password: ${{ secrets.GITHUB_TOKEN }}
27+
28+
- name: Build and push Docker image
29+
uses: docker/build-push-action@e551b19e49efd4e98792db7592c17c09b89db8d8 # v3.0.0
30+
with:
31+
context: "{{ defaultContext }}:server"
32+
push: false
33+
tags: ${{ env.IMAGE_NAME }}
File renamed without changes.

0 commit comments

Comments
 (0)