-
Notifications
You must be signed in to change notification settings - Fork 2
45 lines (41 loc) · 1.12 KB
/
deploy.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
name: Deploy Site
on:
push:
branches:
- master
- v1-prod
pull_request:
branches:
- master
jobs:
publish:
runs-on: ubuntu-latest
steps:
# Get system info
- run: ifconfig
- run: sudo dmidecode
- run: df -h
- run: free -m
- run: echo "GitHub branch is ${{ github.ref }}"
# Install Hugo
# Download latest version of Hugo
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: '0.89.4'
extended: true
# Checks-out your repository under $GITHUB_WORKSPACE,
# so your workflow can access it
- name: Checkout repo
uses: actions/checkout@master
# Build Hugo Site
- run: echo "Building hugo site"
- run: hugo
- name: Publish to Distributed Press
if: ${{ github.ref == 'refs/heads/master' }}
uses: hyphacoop/[email protected]
with:
publish_dir: ./public
dp_url: https://api.distributed.press
refresh_token: ${{ secrets.DISTRIBUTED_PRESS_API_KEY }}
site_url: two.compost.digital