Merge pull request #38 from ESA-VirES/ftp_fixes #67
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
run: | |
name: Build Jupyter Book | |
runs-on: ubuntu-latest | |
steps: | |
- name: Pull docker image | |
run: | | |
echo ${{ secrets.EOX_REGISTRY_PASSWORD }} | docker login -u ${{ secrets.EOX_REGISTRY_USER }} --password-stdin registry.gitlab.eox.at | |
docker pull registry.gitlab.eox.at/esa/vires_vre_ops/vre-aeolus-notebook:0.2.0d | |
- uses: actions/checkout@v2 | |
- name: Execute notebooks and build book | |
run: | | |
docker run -v $GITHUB_WORKSPACE:/home/jovyan -u root \ | |
-e VIRES_TOKEN=${{ secrets.VIRES_TOKEN }} \ | |
-e VIRES_TOKEN_STAGING=${{ secrets.VIRES_TOKEN_STAGING }} \ | |
-e DATAU=${{ secrets.DATAU }} \ | |
-e DATAP=${{ secrets.DATAP }} \ | |
-e CALVALU=${{ secrets.CALVALU }} \ | |
-e CALVALP=${{ secrets.CALVALP }} \ | |
-e CODA_DEFINITION=/usr/share/coda/definitions/ \ | |
registry.gitlab.eox.at/esa/vires_vre_ops/vre-aeolus-notebook:0.2.0d \ | |
bash -c \ | |
' | |
# pip install --upgrade 'git+https://github.com/ESA-VirES/VirES-Python-Client@aeolus#egg=viresclient' && \ | |
viresclient set_token https://aeolus.services/ows $VIRES_TOKEN && \ | |
viresclient set_token https://staging.aeolus.services/ows $VIRES_TOKEN_STAGING && \ | |
viresclient set_default_server https://aeolus.services/ows && \ | |
pip install jupyter-book==0.12.2 nbmake==1.2 pytest-xdist==2.5.0 && \ | |
pytest --numprocesses 2 --nbmake --overwrite notebooks && \ | |
jupyter-book build --config _config.yml . | |
' | |
- name: Deploy preview with netlify | |
run: netlify deploy --dir=_build/html --auth=${{ secrets.NETLIFY_AUTH_TOKEN }} --site=${{ secrets.NETLIFY_SITE_API_ID }} |