File tree Expand file tree Collapse file tree 7 files changed +80
-69
lines changed Expand file tree Collapse file tree 7 files changed +80
-69
lines changed Original file line number Diff line number Diff line change 11name : " Build & Publish Container Image"
22
3- permissions :
4- contents : read
5- packages : write
6-
73on :
84 workflow_call :
95 inputs :
1915
2016jobs :
2117 docker-build :
18+ permissions :
19+ contents : read
20+ packages : write
21+
2222 runs-on : ubuntu-latest
2323 steps :
2424 - uses : actions/checkout@v4
2525 with :
2626 ref : ${{ inputs.tag }}
27+ persist-credentials : false
2728 - name : Setup Docker Buildx
2829 uses : docker/setup-buildx-action@v3
2930 - name : Extract Semver
3031 id : semver
32+ env :
33+ INPUT_TAG : " ${{ inputs.tag }}"
3134 run : |
32- SEMVER_VERSION=$(echo "${{ inputs.tag }} " | sed -E 's/liwan-v//')
35+ SEMVER_VERSION=$(echo "$INPUT_TAG " | sed -E 's/liwan-v//')
3336 echo "SEMVER_VERSION=${SEMVER_VERSION}" >> "$GITHUB_OUTPUT"
3437 - name : Setup Docker Metadata
3538 uses : docker/metadata-action@v5
Original file line number Diff line number Diff line change 11name : Release
22
3- permissions :
4- contents : write
5- packages : write
6-
73on :
84 push :
95 tags :
1410 runs-on : ubuntu-latest
1511 steps :
1612 - uses : actions/checkout@v4
17- - uses : taiki-e/create-gh-release-action@v1
13+ with :
14+ persist-credentials : false
15+ 1816 with :
1917 changelog : CHANGELOG.md
2018 allow-missing-changelog : true
2624 runs-on : ubuntu-latest
2725 steps :
2826 - uses : actions/checkout@v4
27+ with :
28+ persist-credentials : false
2929 - uses : oven-sh/setup-bun@v2
3030 with :
3131 bun-version : latest
4141 path : ./web/dist
4242
4343 upload-assets :
44+ permissions :
45+ contents : write
4446 needs : [create-release, build-web]
4547 strategy :
4648 matrix :
@@ -58,18 +60,22 @@ jobs:
5860 runs-on : ${{ matrix.os }}
5961 steps :
6062 - uses : actions/checkout@v4
63+ with :
64+ persist-credentials : false
6165 - uses : actions/download-artifact@v4
6266 with :
6367 name : web-dist
6468 path : ./web/dist
65- - uses : taiki-e/upload-rust-binary-action@v1
69+ - uses : taiki-e/upload-rust-binary-action@v1.23.0
6670 with :
6771 bin : liwan
6872 target : ${{ matrix.target }}
6973 build-tool : ${{ matrix.build-tool }}
7074 token : ${{ secrets.GITHUB_TOKEN }}
7175
7276 publish-container :
77+ permissions :
78+ packages : write
7379 needs : [create-release, upload-assets]
7480 uses : explodingcamera/liwan/.github/workflows/container.yaml@main
7581 with :
Original file line number Diff line number Diff line change 1818 runs-on : ubuntu-latest
1919 steps :
2020 - uses : actions/checkout@v4
21+ with :
22+ persist-credentials : false
2123 - uses : oven-sh/setup-bun@v2
2224 with :
2325 bun-version : latest
Original file line number Diff line number Diff line change 2222 runs-on : ${{ matrix.os }}
2323 steps :
2424 - uses : actions/checkout@v4
25+ with :
26+ persist-credentials : false
2527 - uses : actions-rust-lang/setup-rust-toolchain@v1
2628 - uses : Swatinem/rust-cache@v2
2729 - run : mkdir ./web/dist
You can’t perform that action at this time.
0 commit comments