Skip to content

build(deps): bump DeterminateSystems/nix-installer-action from 9 to 1… #55

build(deps): bump DeterminateSystems/nix-installer-action from 9 to 1…

build(deps): bump DeterminateSystems/nix-installer-action from 9 to 1… #55

Workflow file for this run

name: Fly Deploy
on:
push:
branches:
- main
permissions:
packages: write
jobs:
deploy:
name: Deploy app
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install nix
uses: DeterminateSystems/nix-installer-action@v10
- name: Setup magic-nix-cache
uses: DeterminateSystems/magic-nix-cache-action@main
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build container
run: |
nix build -L .#jnsgruk-container
- name: Upload container to ghcr.io
run: |
docker load < result
docker tag "jnsgruk/jnsgr.uk:$(git rev-parse --short HEAD)" "ghcr.io/jnsgruk/jnsgr.uk:$(git rev-parse --short HEAD)"
docker push "ghcr.io/jnsgruk/jnsgr.uk:$(git rev-parse --short HEAD)"
- name: Deploy site
run: |
nix run nixpkgs#flyctl -- deploy -i "ghcr.io/jnsgruk/jnsgr.uk:$(git rev-parse --short HEAD)"
env:
FLY_ACCESS_TOKEN: ${{ secrets.FLY_API_TOKEN }}