Skip to content

Commit 526ba38

Browse files
committed
新增自动jib打包docker,上传至腾讯镜像仓库
1 parent 333cd15 commit 526ba38

1 file changed

Lines changed: 27 additions & 0 deletions

File tree

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Build and Push with Jib
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
tags: [ 'v*' ]
7+
pull_request:
8+
branches: [ master ]
9+
10+
jobs:
11+
build-and-push:
12+
runs-on: ubuntu-latest
13+
env:
14+
REGISTRY_URL: 'ccr.ccs.tencentyun.com/opensabre' # 替换为你的镜像提交地址
15+
16+
steps:
17+
- name: Checkout Code
18+
uses: actions/checkout@v4
19+
20+
- name: Set up JDK
21+
uses: actions/setup-java@v4
22+
with:
23+
java-version: '21' # 或你项目使用的JDK版本
24+
distribution: 'temurin'
25+
26+
- name: Build and Push with Jib
27+
run: mvn compile jib:build -Dsecret.id=${{ secrets.TENCENT_CLOUD_SECRET_ID }} -Dsecret.key=${{ secrets.TENCENT_CLOUD_SECRET_KEY }}

0 commit comments

Comments
 (0)