-
Notifications
You must be signed in to change notification settings - Fork 11
61 lines (55 loc) · 1.34 KB
/
publish.yaml
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
59
60
name: publish
on:
push:
tags:
- '*'
branches:
- 'master'
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
build:
runs-on: actuated-4cpu-8gb
steps:
- uses: actions/checkout@v3
with:
repository: inlets/inlets.dev
fetch-depth: 1
- name: Reset hostedtoolcache permissions
run: |
sudo mkdir -p /opt/hostedtoolcache
sudo chown -R $(whoami) /opt/hostedtoolcache
- name: Add rubygems
run: |
sudo apt install rubygems -y
- uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
bundler-cache: true
- name: Add bundler
run: |
sudo gem install bundler:2.2.13
- name: Install deps
run: |
bundle install && yarn install
- name: Build site
run: |
JEKYLL_ENV=production bundle exec jekyll build -d _site
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: actuated-4cpu-8gb
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1