Skip to content

Actualiza_productos_UC #3330

Actualiza_productos_UC

Actualiza_productos_UC #3330

Workflow file for this run

# This is a basic workflow to help you get started with Actions
name: Actualiza_productos_UC
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
branches: master
paths: '.github/workflows/UC.yml'
schedule:
- cron: '20 00-04 * * *'
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
Actualiza_productos_de_UC:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: Check out our repo
uses: actions/checkout@v2
with:
path: Datos-COVID19
- name: 'Check out datagovuc/ICOVID'
uses: actions/checkout@v2
env:
GITHUB_TOKEN: ${{ secrets.DO_AUTOMATION_BOT_PAT }}
with:
token: ${{ env.GITHUB_TOKEN }}
repository: datagovuc/ICOVID
path: ICOVID
# Sets up python
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: 3.8
# Runs a set of commands using the runners shell
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r Datos-COVID19/requirements.txt
- name: generate products for UC
run: |
pwd
ls
ls -la Datos-COVID19/input/UC
rsync -av --exclude "README.md" ICOVID/DO/ Datos-COVID19/input/UC
rm -rf ICOVID
ls -la Datos-COVID19/input/UC
cd Datos-COVID19/src
python UC.py
- uses: stefanzweifel/[email protected]
with:
commit_message: "Added data from UC to repo"
# Optional glob pattern of files which should be added to the commit
#file_pattern: output/*/*.csv
# Optional local file path to the repository
repository: Datos-COVID19
# Optional commit user and author settings
commit_user_name: MinCiencia GitHub Actions Bot
commit_user_email: [email protected]
commit_author: minciencia github bot <[email protected]>
# - name: update_API
# run: |
# curl -u "${{ secrets.DO_INT_USER }}:${{ secrets.DO_INT_PASS }}" \
# -H 'Accept: application/vnd.github.everest-preview+json' "https://api.github.com/repos/Data-Observatory/covid19-API/dispatches" \
# -d '{"event_type": "update_please_from_reporte_diario"}'