-
Notifications
You must be signed in to change notification settings - Fork 1
39 lines (37 loc) · 943 Bytes
/
ci.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
on:
push:
tags:
branches:
- hexo
pull_request:
name: Hexo
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
with:
fetch-depth: 2
- name: Fetch md source
run: $PWD/bin/build.sh git
- name: SSH settings
if: github.event_name == 'push'
uses: Homebrew/actions/git-ssh@master
with:
git_user: Kang Huaishuai
git_email: [email protected]
key_name: id_rsa
key: ${{ secrets.SSH_KEY }}
- name: Hexo Build
uses: docker://khs1994/hexo
- name: Hexo Deploy
if: github.event_name == 'push'
run: |
docker run -i --rm \
-v $PWD:/srv/hexo-src \
-v ~/.ssh:/root/.ssh \
-e GIT_USERNAME="Kang Huaishuai" \
-e [email protected] \
khs1994/hexo \
deploy