-
Notifications
You must be signed in to change notification settings - Fork 173
53 lines (45 loc) · 1.6 KB
/
check-links.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
name: Check Links
on:
repository_dispatch:
workflow_dispatch:
pull_request:
branches:
- main
schedule:
- cron: "0 0 * * *"
jobs:
linkChecker:
runs-on: ubuntu-latest
steps:
- name: Waiting for Netlify Preview
uses: jakepartusch/wait-for-netlify-action@f1e137043864b9ab9034ae3a5adc1c108e3f1a48 # v1.4
id: wait-for-netflify-preview
with:
site_name: kyverno
max_timeout: 60
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Setup Hugo
uses: peaceiris/actions-hugo@16361eb4acea8698b220b76c0d4e84e1fd22c61d # v2.6.0
with:
hugo-version: latest
extended: true
- name: Install site dependencies
run: npm install --save-dev autoprefixer && npm install --save-dev postcss-cli && npm install -D postcss
- name: Build site with Hugo
run: hugo --minify -b ${{ steps.wait-for-netflify-preview.outputs.url }}
- name: Link Checker
id: lychee
uses: lycheeverse/lychee-action@c053181aa0c3d17606addfe97a9075a32723548a # v1.9.3
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
with:
fail: true
debug: false
args: --no-progress --github-token ${{secrets.GITHUB_TOKEN}} -c lychee.toml -E public
# - name: Create Issue From File
# if: steps.lychee.outputs.exit_code != 0
# uses: peter-evans/create-issue-from-file@v3
# with:
# title: Link Checker Report
# content-filepath: ./lychee/out.md
# labels: report, automated issue