Skip to content

Build

Build #1

Workflow file for this run

name: 'Build'
on:
create:
branches:
- 'master'
jobs:
deploy:
if: startsWith(github.repository, 'ModdingX/') # don't run in forks
runs-on: ubuntu-latest
steps:
- name: 'Checkout'
uses: actions/checkout@v3
with:
submodules: true
- name: 'Apply patches'
run: ./gradlew applyPatches
- name: 'Build container'
shell: bash
working-directory: target
run: |
docker build -t "ghcr.io/ModdingX/reposilite-patches:latest" -t "ghcr.io/ModdingX/reposilite-patches:${github.ref_name}" .
- name: 'Login to GitHub package registry'
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: 'Publish container'
shell: bash
run: |
docker push "ghcr.io/ModdingX/reposilite-patches:${github.ref_name}"
docker push "ghcr.io/ModdingX/reposilite-patches:latest"