Skip to content

Commit 1a959fb

Browse files
committed
feat:make image every push
Signed-off-by: Chen Kai <281165273grape@gmail.com>
1 parent e52ff16 commit 1a959fb

2 files changed

Lines changed: 45 additions & 1 deletion

File tree

.github/workflows/image.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: shisui latest image
2+
3+
on:
4+
push:
5+
branches: [ portal ]
6+
7+
defaults:
8+
run:
9+
shell: bash
10+
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.ref }}
13+
cancel-in-progress: true
14+
15+
permissions:
16+
contents: write
17+
18+
env:
19+
REGISTRY: ghcr.io
20+
IMAGE_NAME: ${{ github.repository }}
21+
22+
jobs:
23+
24+
push_image_to_github:
25+
name: Push Docker image to Github
26+
runs-on: ubuntu-latest
27+
permissions: write-all
28+
steps:
29+
- name: Check out the repo
30+
uses: actions/checkout@v4
31+
- name: Log in to Docker Hub
32+
uses: docker/login-action@v3
33+
with:
34+
registry: ${{ env.REGISTRY }}
35+
username: ${{ github.actor }}
36+
password: ${{ secrets.GITHUB_TOKEN }}
37+
38+
- name: Build and push Docker image
39+
uses: docker/build-push-action@v5
40+
with:
41+
context: .
42+
file: ./Dockerfile.portal
43+
push: true
44+
tags: ${{ env.REGISTRY }}/${{ github.repository }}:latest

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: shisui image
1+
name: shisui release image
22

33
on:
44
release:

0 commit comments

Comments
 (0)