File tree Expand file tree Collapse file tree 1 file changed +37
-0
lines changed
Expand file tree Collapse file tree 1 file changed +37
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Docker Image CI
2+ on :
3+ workflow_dispatch : # 允许手动触发工作流
4+
5+ jobs :
6+ build :
7+ runs-on : ubuntu-latest
8+ strategy :
9+ matrix :
10+ architecture : [amd64, arm64]
11+ os : [linux]
12+
13+ steps :
14+ - name : Checkout code
15+ uses : actions/checkout@v2
16+
17+ - name : Set up QEMU
18+ uses : docker/setup-qemu-action@v1
19+
20+ - name : Set up Buildx
21+ uses : docker/setup-buildx-action@v1
22+
23+ - name : Log in to GitHub Container Registry
24+ uses : docker/login-action@v1
25+ with :
26+ registry : ghcr.io
27+ username : ${{ github.actor }} # 使用当前 GitHub 用户名
28+ password : ${{ secrets.CR_TOKEN }} # 使用您刚刚添加的个人访问令牌
29+
30+ - name : Build and push
31+ uses : docker/build-push-action@v2
32+ with :
33+ context : .
34+ file : ./Dockerfile_frontend
35+ push : true
36+ tags : ghcr.io/lightislost/ekgfrontend:0.1.0
37+ platforms : ${{ matrix.os }}/${{ matrix.architecture }}
You can’t perform that action at this time.
0 commit comments