dockers/.gitea/workflows/minecraft-builder.yml
shockrah 116de4f9f1
All checks were successful
Build Minecraft Image / build-minecraft-image (push) Successful in 7s
Build Minecraft Image / push-to-docker-hub (push) Successful in 9s
Building a test image for minecraft
2024-12-10 17:00:59 -08:00

30 lines
744 B
YAML

name: Build Minecraft Image
on:
push:
branches:
- master
paths:
- minecraft/*
env:
image: shockrah/minecraft
jobs:
build-minecraft-image:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Build docker image
run: docker build -t ${{ env.image }} ${{ gitea.workspace }}/website
push-to-docker-hub:
needs: build-hugo-image
runs-on: ubuntu-latest
steps:
- name: Login to Docker Hub
run: |
echo "${{ secrets.dockerhub_pass }}" | \
docker login -u ${{ secrets.dockerhub_user }} --password-stdin
- name: Push Docker image from previous job
run: docker push ${{ env.image }}