-
-
Notifications
You must be signed in to change notification settings - Fork 1
45 lines (39 loc) · 1.16 KB
/
main.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: main
on:
push:
branches:
- main
jobs:
main:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Restore cache
uses: actions/cache@v4
with:
path: cache
key: ${{ runner.os }}-cache
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: "1.21"
- name: Build
env:
ROOT_URL: https://chuhlomin.com
REMOVE_HTML_EXT: "1"
COMMENTS_ENABLED: "1"
COMMENTS_SITE_ID: "micro"
SEARCH_ENABLED: "1"
SEARCH_HOST: "https://search.chuhlomin.com/"
SEARCH_MASTER_KEY: ${{ secrets.SEARCH_MASTER_KEY }}
SEARCH_API_KEY: ${{ secrets.SEARCH_API_KEY }}
run:
make build
- name: Deploy
uses: cloudflare/wrangler-action@v3.5.0
if: github.event_name == 'push' && !contains(github.event.head_commit.message, '[skip deploy]')
with:
apiToken: ${{ secrets.CF_API_TOKEN }}
accountId: ${{ secrets.CF_ACCOUNT_ID }}
command: pages deploy output --project-name=homepage --branch=main --commit-dirty=true