mirror of
https://github.com/TeamPiped/Piped-Backend
synced 2025-09-05 21:11:05 +02:00
Use common fat-build workflow.
This commit is contained in:
parent
261fba8238
commit
2864af856b
16
.github/workflows/docker-build-test.yml
vendored
16
.github/workflows/docker-build-test.yml
vendored
@ -9,8 +9,12 @@ on:
|
|||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
build-jdk:
|
||||||
|
uses: ./.github/workflows/fat-build.yml
|
||||||
|
|
||||||
build-test:
|
build-test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
needs: build-jdk
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
docker-compose-file:
|
docker-compose-file:
|
||||||
@ -31,17 +35,11 @@ jobs:
|
|||||||
fail-fast: false
|
fail-fast: false
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
- uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: piped.jar
|
||||||
- name: Create Version File
|
- name: Create Version File
|
||||||
run: echo $(git log -1 --date=short --pretty=format:%cd)-$(git rev-parse --short HEAD) > VERSION
|
run: echo $(git log -1 --date=short --pretty=format:%cd)-$(git rev-parse --short HEAD) > VERSION
|
||||||
- name: set up JDK 17
|
|
||||||
uses: actions/setup-java@v3
|
|
||||||
with:
|
|
||||||
java-version: 17
|
|
||||||
distribution: temurin
|
|
||||||
cache: "gradle"
|
|
||||||
- name: Run Build
|
|
||||||
run: ./gradlew shadowJar
|
|
||||||
- run: mv build/libs/piped-*-all.jar piped.jar
|
|
||||||
- name: Build Image Locally
|
- name: Build Image Locally
|
||||||
uses: docker/build-push-action@v4
|
uses: docker/build-push-action@v4
|
||||||
with:
|
with:
|
||||||
|
16
.github/workflows/docker-build.yml
vendored
16
.github/workflows/docker-build.yml
vendored
@ -8,7 +8,11 @@ on:
|
|||||||
- master
|
- master
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
build-jdk:
|
||||||
|
uses: ./.github/workflows/fat-build.yml
|
||||||
|
|
||||||
build-docker:
|
build-docker:
|
||||||
|
needs: build-jdk
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
@ -23,17 +27,11 @@ jobs:
|
|||||||
dockerfile: ./Dockerfile.graalvm-jvm.ci
|
dockerfile: ./Dockerfile.graalvm-jvm.ci
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
- uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: piped.jar
|
||||||
- name: Create Version File
|
- name: Create Version File
|
||||||
run: echo $(git log -1 --date=short --pretty=format:%cd)-$(git rev-parse --short HEAD) > VERSION
|
run: echo $(git log -1 --date=short --pretty=format:%cd)-$(git rev-parse --short HEAD) > VERSION
|
||||||
- name: set up JDK 17
|
|
||||||
uses: actions/setup-java@v3
|
|
||||||
with:
|
|
||||||
java-version: 17
|
|
||||||
distribution: temurin
|
|
||||||
cache: "gradle"
|
|
||||||
- name: Run Build
|
|
||||||
run: ./gradlew shadowJar
|
|
||||||
- run: mv build/libs/piped-*-all.jar piped.jar
|
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
uses: docker/setup-qemu-action@v2
|
uses: docker/setup-qemu-action@v2
|
||||||
with:
|
with:
|
||||||
|
24
.github/workflows/fat-build.yml
vendored
Normal file
24
.github/workflows/fat-build.yml
vendored
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
name: Fat JAR Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-and-test:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: set up JDK 17
|
||||||
|
uses: actions/setup-java@v3
|
||||||
|
with:
|
||||||
|
java-version: 17
|
||||||
|
distribution: temurin
|
||||||
|
cache: "gradle"
|
||||||
|
- name: Run Build
|
||||||
|
run: ./gradlew shadowJar
|
||||||
|
- run: mv build/libs/piped-*-all.jar piped.jar
|
||||||
|
- uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: piped.jar
|
||||||
|
path: piped.jar
|
Loading…
x
Reference in New Issue
Block a user