Update github actions (#227)
This commit is contained in:
parent
1407641e45
commit
7426982b07
16
.github/workflows/cron.yml
vendored
16
.github/workflows/cron.yml
vendored
|
@ -31,13 +31,18 @@ jobs:
|
|||
fetch-depth: 0
|
||||
|
||||
- name: Installing Nix
|
||||
uses: cachix/install-nix-action@v8
|
||||
uses: cachix/install-nix-action@v12
|
||||
|
||||
- uses: cachix/cachix-action@v6
|
||||
- uses: cachix/cachix-action@v8
|
||||
with:
|
||||
name: nixos-search
|
||||
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
|
||||
|
||||
- name: Install unstable channel
|
||||
run: |
|
||||
nix-channel --add https://nixos.org/channels/nixpkgs-unstable
|
||||
nix-channel --update
|
||||
|
||||
- name: Installing awscli
|
||||
run: |
|
||||
nix-env -iA nixpkgs.awscli
|
||||
|
@ -50,7 +55,7 @@ jobs:
|
|||
RELEASE=$(aws s3 ls --no-sign-request "$S3_URL/" | grep "nixpkgs-${{ matrix.channel }}pre" | grep "/$" | cut -d" " -f29 | sort | tail -1 | sed 's|/||')
|
||||
fi
|
||||
aws s3 cp --no-sign-request "$S3_URL/$RELEASE/src-url" ./
|
||||
echo "::set-env name=EVAL_ID::$(cat src-url | cut -c30-)"
|
||||
echo "EVAL_ID=$(cat src-url | cut -c30-)" >> $GITHUB_ENV
|
||||
|
||||
- name: Download latest builds for ${{ matrix.channel }} channel (if needed)
|
||||
if: steps.eval-cache.outputs.cache-hit != 'true'
|
||||
|
@ -69,14 +74,13 @@ jobs:
|
|||
- name: Installing NixFlakes
|
||||
run: |
|
||||
nix-env -iA nixpkgs.nixFlakes
|
||||
echo "::add-path::$HOME/.nix-profile/bin"
|
||||
echo 'experimental-features = nix-command flakes' | sudo tee -a /etc/nix/nix.conf
|
||||
nix --version
|
||||
$HOME/.nix-profile/bin/nix --version
|
||||
cat /etc/nix/nix.conf
|
||||
|
||||
- name: Building import_scripts
|
||||
run: |
|
||||
nix build ./#packages.x86_64-linux.import_scripts
|
||||
$HOME/.nix-profile/bin/nix build ./#packages.x86_64-linux.import_scripts
|
||||
|
||||
- name: Import ${{ matrix.channel }} channel
|
||||
run: |
|
||||
|
|
16
.github/workflows/main.yml
vendored
16
.github/workflows/main.yml
vendored
|
@ -14,33 +14,37 @@ jobs:
|
|||
fetch-depth: 0
|
||||
|
||||
- name: Installing Nix
|
||||
uses: cachix/install-nix-action@v9
|
||||
uses: cachix/install-nix-action@v12
|
||||
|
||||
- uses: cachix/cachix-action@v6
|
||||
- uses: cachix/cachix-action@v8
|
||||
with:
|
||||
name: nixos-search
|
||||
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
|
||||
|
||||
- name: Install unstable channel
|
||||
run: |
|
||||
nix-channel --add https://nixos.org/channels/nixpkgs-unstable
|
||||
nix-channel --update
|
||||
|
||||
- name: Installing NixFlakes
|
||||
run: |
|
||||
nix-env -iA nixpkgs.nixFlakes
|
||||
echo "::add-path::$HOME/.nix-profile/bin"
|
||||
echo 'experimental-features = nix-command flakes' | sudo tee -a /etc/nix/nix.conf
|
||||
nix --version
|
||||
cat /etc/nix/nix.conf
|
||||
|
||||
- name: Building import_scripts
|
||||
run: |
|
||||
nix build ./#packages.x86_64-linux.import_scripts
|
||||
$HOME/.nix-profile/bin/nix build ./#packages.x86_64-linux.import_scripts
|
||||
|
||||
- name: Building search.nixos.org
|
||||
run: |
|
||||
nix build ./#packages.x86_64-linux.frontend
|
||||
$HOME/.nix-profile/bin/nix build ./#packages.x86_64-linux.frontend
|
||||
mkdir ./dist
|
||||
cp -RL ./result/* ./dist/
|
||||
|
||||
- name: Deploy to Netlify
|
||||
uses: nwtgck/actions-netlify@v1.0.5
|
||||
uses: nwtgck/actions-netlify@v1.1.11
|
||||
env:
|
||||
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
|
||||
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
|
||||
|
|
Loading…
Reference in a new issue