iocaine/.forgejo/workflows/build.yaml
Gergely Nagy 65cc8365d6
ci: build & publish the container image too
Signed-off-by: Gergely Nagy <me@gergo.csillger.hu>
2025-01-16 19:31:44 +01:00

50 lines
1.1 KiB
YAML

## SPDX-FileCopyrightText: 2025 Gergely Nagy
## SPDX-FileContributor: Gergely Nagy
##
## SPDX-License-Identifier: MIT
name: build
on:
push:
branches:
- 'main'
jobs:
build:
runs-on: nixos-latest
steps:
- name: checkout
uses: actions/checkout@v4
- name: setup magic attic cache
uses: actions/magic-attic-cache@main
with:
ATTIC_TOKEN: ${{ secrets.ATTIC_TOKEN }}
- name: build
uses: actions/nix/build@main
with:
logs: true
package: iocaine
- name: build the container image
uses: actions/nix/build@main
with:
logs: true
package: container-image
- name: load the container image into docker
run: |
docker load <result
- name: login to the container registry
uses: https://code.forgejo.org/docker/login-action@v2
with:
registry: git.madhouse-project.org
username: algernon
password: ${{ secrets.DOCKER_PASSWORD }}
- name: publish
run:
docker push git.madhouse-project.org/algernon/iocaine:latest