Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
aquestry committed Dec 30, 2024
1 parent 8a82ffd commit 8e5ef15
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 28 deletions.
35 changes: 7 additions & 28 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
@@ -1,49 +1,28 @@
name: Docker Image CI

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

permissions:
contents: read
packages: write

jobs:
build:
push-image:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up JDK 21
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '21'

- name: Build with Maven
run: mvn clean package

- name: Cache Docker layers
uses: actions/cache@v3
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-
- name: Check out code
uses: actions/checkout@v4
- name: Log in to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Build and push Docker image
run: |
docker buildx create --use
docker buildx build --platform linux/arm64,linux/amd64 --tag anton691/simple-parkour:latest --push .
docker buildx build \
--platform linux/arm64,linux/amd64 \
--tag anton691/simple-parkour:latest \
--push .
Binary file modified target/server.jar
Binary file not shown.

0 comments on commit 8e5ef15

Please sign in to comment.