CI checks for 404 and websocket availability.

This commit is contained in:
David Himmelstrup 2020-09-22 13:28:35 +08:00
commit d40aed29f6

27
.github/workflows/site-checks.yml vendored Normal file
View file

@ -0,0 +1,27 @@
name: Site checker
on:
schedule:
- cron: "0 * * * *"
push:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install dependencies
run: |
apt install w3c-linkchecker node-ws
- name: Check websocket connection
run: |
wscat --connect "wss://reanimate.clozecards.com:443/ws/" --execute "GET /\n"
- name: Check links at reanimate.github.io
run: |
FAILURES=$(checklink --quiet --broken "https://reanimate.github.io/")
if [ -n "$FAILURES" ]; then
echo $FAILURES
exit 1
fi