Skip to content

Commit

Permalink
Build with github action : push on main
Browse files Browse the repository at this point in the history
  • Loading branch information
fxi committed Jul 5, 2024
1 parent 833f10b commit a6b42f2
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 54 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build and Push Docker Image

on:
push:
branches:
- main

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

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

- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: fredmoser/inaccessmod:latest
platforms: linux/amd64,linux/arm64
52 changes: 0 additions & 52 deletions build.log

This file was deleted.

4 changes: 2 additions & 2 deletions build.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash

# require buildx (--load)
docker build --load -t fredmoser/inaccessmod . 2>&1 | tee build.log

echo "Build on push with github actions"

0 comments on commit a6b42f2

Please sign in to comment.