Notifications #810
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 }} | |
if: github.event_name == 'push' && github.ref == 'refs/heads/master' |