File tree Expand file tree Collapse file tree 1 file changed +51
-0
lines changed
Expand file tree Collapse file tree 1 file changed +51
-0
lines changed Original file line number Diff line number Diff line change 1+ # 构建Docker镜像
2+ name : Docker-Image
3+
4+ on :
5+ push : # 推送的时候触发
6+ # branches: [ "master" ] # 推送的分支
7+ # Publish semver tags as releases.
8+ # tags: [ 'v*.*.*' ]
9+ # 手动触发部署
10+ workflow_dispatch :
11+ # pull_request:
12+ # branches: [ "next" ]
13+
14+ env :
15+ # 仓库地址
16+ REGISTRY : registry.cn-hangzhou.aliyuncs.com
17+ UserName : mmdapl
18+
19+
20+ jobs :
21+ Docker-Image :
22+ name : " 构建Docker镜像"
23+ runs-on : ubuntu-latest
24+ permissions :
25+ contents : read
26+ packages : write
27+ # This is used to complete the identity challenge
28+ # with sigstore/fulcio when running outside of PRs.
29+ id-token : write
30+
31+ steps :
32+ - name : Checkout repository
33+ uses : actions/checkout@v3
34+
35+ - name : Login Docker
36+ run : |
37+ docker version;
38+ # 登录阿里云镜像仓库
39+ docker login --username=${{ env.UserName }} --password=${{ secrets.Docker_Password }} ${{env.REGISTRY}}
40+
41+ - name : PNPM Install
42+ uses : pnpm/action-setup@v2
43+ with :
44+ version : 7
45+ node-version : 14.20.1
46+ # 使用 pnpm 安装依赖
47+ run_install : true
48+
49+ - name : Build And Push Docker image
50+ run :
51+ PROXY_DOMAIN=true pnpm faster-image
You can’t perform that action at this time.
0 commit comments