-
Notifications
You must be signed in to change notification settings - Fork 0
58 lines (50 loc) · 1.46 KB
/
build_and_release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: "Build Site and Deploy"
on:
push:
branches:
- 'release'
jobs:
build_and_deploy:
name: Build and deploy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Install Nix
if: success()
uses: cachix/install-nix-action@v30
- uses: cachix/cachix-action@v15
with:
name: aciceri-blog
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- name: Build
if: success()
run: nix build --accept-flake-config -L
# - name: Push on Pinata
# id: ipfs
# if: success()
# uses: aquiladev/[email protected]
# with:
# path: ./result
# service: pinata
# pinataKey: ${{ secrets.API_KEY }}
# pinataSecret: ${{ secrets.API_SECRET }}
# - name: Update DNS with new IPFS hash
# if: success()
# env:
# CLOUDFLARE_TOKEN: ${{ secrets.CLOUDFLARE_TOKEN }}
# RECORD_DOMAIN: 'aciceri.dev'
# RECORD_NAME: '_dnslink.blog'
# CLOUDFLARE_ZONE_ID: ${{ secrets.CLOUDFLARE_ZONE_ID }}
# uses: textileio/[email protected]
# with:
# cid: ${{ steps.ipfs.outputs.hash }}
- name: Deploy on Github Pages
if: success()
uses: crazy-max/ghaction-github-pages@v2
with:
target_branch: gh-pages
build_dir: ./result
follow_symlinks: true
fqdn: blog.aciceri.dev
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}