Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add workflow to build Docker images #1166

Merged
merged 4 commits into from
Aug 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,10 @@ jobs:
fail-fast: false
matrix:
image:
- "nas2d-arch:1.4"
- "nas2d-arch:1.5"
runs-on: ubuntu-latest
container:
image: "outpostuniverse/${{ matrix.image }}"
image: "ghcr.io/${{ github.repository_owner }}/${{ matrix.image }}"

steps:
- uses: actions/checkout@v4
Expand Down
29 changes: 29 additions & 0 deletions .github/workflows/dockerBuild.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Docker Build

on:
push:
paths:
- ".github/workflows/dockerBuild.yml"
- "docker/*"
workflow_dispatch:

jobs:
dockerBuild:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
platform:
- "arch"
env:
DockerRepository: ghcr.io/${{ github.repository_owner }}

steps:
- uses: actions/checkout@v4

- run: make -C docker build-image-${{ matrix.platform }}

- name: Docker login
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io --username "${{ github.repository_owner }}" --password-stdin

- run: make -C docker push-image-${{ matrix.platform }}
2 changes: 1 addition & 1 deletion docker/makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TopLevelFolder := $(abspath $(DockerFolder)/..)

DockerRunFlags := --volume ${TopLevelFolder}:/code --workdir=/code --rm --tty
DockerUserFlags = --user="$(shell id --user):$(shell id --group)"
DockerRepository := outpostuniverse
DockerRepository ?= outpostuniverse

include $(wildcard $(DockerFolder)/nas2d-*.version.mk)

Expand Down
2 changes: 1 addition & 1 deletion docker/nas2d-arch.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# See Docker section of makefile in root project folder for usage commands.

FROM archlinux:base-20230604.0.155602
FROM archlinux:base-20240811.0.253648

# Install base development tools
# Includes tools to build download, unpack, and build source packages
Expand Down
2 changes: 1 addition & 1 deletion docker/nas2d-arch.version.mk
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ImageVersion_arch := 1.4
ImageVersion_arch := 1.5