chore: demo

This commit is contained in:
Guido García 2021-01-13 18:05:07 +01:00
parent 9fb00a2fbe
commit 401adaca16
3 changed files with 20 additions and 13 deletions

View File

@ -4,6 +4,7 @@ on:
# TODO enable scheduled execution
# schedule:
# - cron: 0/5 * * * *
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
@ -12,13 +13,11 @@ jobs:
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
# Runs a set of commands using the runners shell
- name: Run a multi-line script
run: |
echo $GITHUB_WORKSPACE
cat $GITHUB_WORKSPACE/sites.csv
echo Add other actions to build,
echo test, and deploy your project.
- name: Crawl information about public sites
run: $GITHUB_WORKSPACE/crawl.sh
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Update information about public sites

8
crawl.sh Executable file
View File

@ -0,0 +1,8 @@
#!/usr/bin/env bash
SITES=`cat sites.csv | cut -d ',' -f 1`
for site in $SITES; do
# see https://github.com/mozilla/http-observatory/blob/master/httpobs/docs/api.md
echo "Scanning $site using Mozilla HTTP Observatory API"
curl -s -X POST "https://http-observatory.security.mozilla.org/api/v1/analyze?host=$site&rescan=true" > output/$site
done

View File

@ -1,5 +1,5 @@
https://www.auvasa.es,AUVASA
https://www.valladolid.es,Ayuntamiento de Valladolid
http://www.museocienciavalladolid.es,Museo de la Ciencia
https://www.uva.es,Universidad de Valladolid
http://www.casadelaindia.org/,Casa de la India
www.auvasa.es,AUVASA
www.valladolid.es,Ayuntamiento de Valladolid
www.museocienciavalladolid.es,Museo de la Ciencia
www.uva.es,Universidad de Valladolid
www.casadelaindia.org,Casa de la India

1 https://www.auvasa.es www.auvasa.es AUVASA
2 https://www.valladolid.es www.valladolid.es Ayuntamiento de Valladolid
3 http://www.museocienciavalladolid.es www.museocienciavalladolid.es Museo de la Ciencia
4 https://www.uva.es www.uva.es Universidad de Valladolid
5 http://www.casadelaindia.org/ www.casadelaindia.org Casa de la India