ci: also publish to GitHub Packages (#54)
Allow Github users to not have another external dependency.
This commit is contained in:
parent
3edc0c92e1
commit
0ce26f2035
1 changed files with 20 additions and 2 deletions
22
.github/workflows/nix.yml
vendored
22
.github/workflows/nix.yml
vendored
|
@ -8,6 +8,7 @@ on:
|
||||||
schedule:
|
schedule:
|
||||||
# Run once per day
|
# Run once per day
|
||||||
- cron: '0 0 * * *'
|
- cron: '0 0 * * *'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
strategy:
|
strategy:
|
||||||
|
@ -18,9 +19,14 @@ jobs:
|
||||||
- nixos-unstable
|
- nixos-unstable
|
||||||
- nixos-24.05
|
- nixos-24.05
|
||||||
system:
|
system:
|
||||||
- x86_64-linux
|
|
||||||
- aarch64-linux
|
- aarch64-linux
|
||||||
|
- x86_64-linux
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
packages: write
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
|
@ -33,12 +39,24 @@ jobs:
|
||||||
extra-platforms = aarch64-linux
|
extra-platforms = aarch64-linux
|
||||||
- uses: DeterminateSystems/magic-nix-cache-action@main
|
- uses: DeterminateSystems/magic-nix-cache-action@main
|
||||||
|
|
||||||
- run: nix-shell --run ./ci.sh
|
- name: Push to Docker Hub
|
||||||
|
run: nix-shell --run ./ci.sh
|
||||||
env:
|
env:
|
||||||
|
CI_PROJECT_PATH: 'nixpkgs'
|
||||||
|
CI_REGISTRY: 'docker.io'
|
||||||
CI_REGISTRY_AUTH: '${{ secrets.REGISTRY_AUTH }}'
|
CI_REGISTRY_AUTH: '${{ secrets.REGISTRY_AUTH }}'
|
||||||
NIXPKGS_CHANNEL: '${{ matrix.channel }}'
|
NIXPKGS_CHANNEL: '${{ matrix.channel }}'
|
||||||
NIX_SYSTEM_NAME: '${{ matrix.system }}'
|
NIX_SYSTEM_NAME: '${{ matrix.system }}'
|
||||||
|
|
||||||
|
- name: Push to GitHub Pages
|
||||||
|
run: nix-shell --run ./ci.sh
|
||||||
|
env:
|
||||||
|
CI_PROJECT_PATH: 'nix-community/docker-nixpkgs'
|
||||||
|
CI_REGISTRY: 'ghcr.io'
|
||||||
|
CI_REGISTRY_AUTH: '${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}'
|
||||||
|
NIXPKGS_CHANNEL: '${{ matrix.channel }}'
|
||||||
|
NIX_SYSTEM_NAME: '${{ matrix.system }}'
|
||||||
|
|
||||||
push-manifest:
|
push-manifest:
|
||||||
needs: [build]
|
needs: [build]
|
||||||
strategy:
|
strategy:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue