Skip to content

Merge pull request #124 from Thymis-io/disable-auto-build #748

Merge pull request #124 from Thymis-io/disable-auto-build

Merge pull request #124 from Thymis-io/disable-auto-build #748

Workflow file for this run

name: "Build"
on:
pull_request:
merge_group:
push:
branches:
- master
jobs:
build-image:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Nix
uses: cachix/install-nix-action@v27
with:
extra_nix_config: |
system-features = kvm
extra-trusted-public-keys = cache.thymis.io-1:pEeKkNXiK17TLKls0KM8cEp0NGy08gc5chAmCyuQo8M=
extra-substituters = https://cache.thymis.io
- uses: DeterminateSystems/magic-nix-cache-action@v2
- name: pin nixpkgs
run: nix registry add nixpkgs github:NixOS/nixpkgs/nixos-24.05
- name: build thymis-controller-generic-x86_64-image
run: nix build .#thymis-controller-generic-x86_64-image --print-build-logs
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Nix
uses: cachix/install-nix-action@v27
with:
extra_nix_config: |
system-features = kvm
extra-trusted-public-keys = cache.thymis.io-1:pEeKkNXiK17TLKls0KM8cEp0NGy08gc5chAmCyuQo8M=
extra-substituters = https://cache.thymis.io
- uses: DeterminateSystems/magic-nix-cache-action@v2
- name: build controller
run: nix build .#thymis-controller-container --print-build-logs
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Push controller image
run: |
docker load < result
docker tag $(docker images --format "{{.Repository}}:{{.Tag}}" | grep thymis-controller) ghcr.io/thymis-io/thymis-controller:${{ github.sha }}
docker push ghcr.io/thymis-io/thymis-controller:${{ github.sha }}