Skip to content

Commit

Permalink
chore(action): docker打包配置
Browse files Browse the repository at this point in the history
  • Loading branch information
nineya committed Jun 16, 2023
1 parent 43de474 commit 3e99c3a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
20 changes: 10 additions & 10 deletions .github/workflows/halo.yml → .github/workflows/halo-plus.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Halo CI
name: Halo-Plus CI

on:
pull_request:
Expand Down Expand Up @@ -64,9 +64,9 @@ jobs:
github-release:
runs-on: ubuntu-latest
needs: build
if: github.event_name == 'release'
if: github.event_name != 'release'
steps:
- name: Download halo jar
- name: Download halo-plus jar
uses: actions/download-artifact@v2
with:
name: halo-plus-jar
Expand All @@ -85,7 +85,7 @@ jobs:
uses: actions/github-script@v2
if: github.event_name == 'release'
with:
github-token: ${{secrets.GITHUB_TOKEN}}
github-token: ${{secrets.GIT_TOKEN}}
script: |
console.log('environment', process.versions);
Expand All @@ -108,23 +108,23 @@ jobs:
docker-release:
runs-on: ubuntu-latest
needs: build
if: github.event_name == 'release'
if: github.event_name != 'release'
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Download halo jar
- name: Download halo-plus jar
uses: actions/download-artifact@v2
with:
name: halo-jar
name: halo-plus-jar
path: build/libs
- name: Docker meta for Halo
id: meta
uses: docker/metadata-action@v3
with:
images: |
halohub/halo
ghcr.io/${{ github.repository_owner }}/halo
nineya/halo-plus
ghcr.io/${{ github.repository_owner }}/halo-plus
tags: |
type=schedule
type=ref,event=branch
Expand All @@ -146,7 +146,7 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GHCR_TOKEN }}
password: ${{ secrets.GIT_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v2
with:
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ RUN java -Djarmode=layertools -jar application.jar extract
################################

FROM eclipse-temurin:11-jre
MAINTAINER johnniang <johnniang@fastmail.com>
MAINTAINER nineya <lsw@nineya.com>
WORKDIR application
COPY --from=builder application/dependencies/ ./
COPY --from=builder application/spring-boot-loader/ ./
Expand Down

0 comments on commit 3e99c3a

Please sign in to comment.