Merge pull request #43 from PetrosStav/patch-3 #87
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] | |
workflow_dispatch: | |
name: Render indicator handbook | |
jobs: | |
build_deploy: | |
runs-on: ubuntu-latest | |
if: github.repository == 'PathOS-project/indicator_handbook' | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Setup quarto | |
uses: quarto-dev/quarto-actions/setup@v2 | |
- name: Setup pandoc | |
uses: r-lib/actions/setup-pandoc@v2 | |
- name: Check quarto | |
run: quarto check | |
- name: (Causal intro) Install system dependencies | |
run: sudo apt install -y libglpk40 libpoppler-cpp-dev poppler-data libjpeg-dev libmagick++-dev libcurl4-openssl-dev libharfbuzz-dev libfribidi-dev | |
- name: (Causal intro) Setup renv | |
uses: r-lib/actions/setup-renv@v2 | |
with: | |
working-directory: causal_intro | |
- name: (Causal intro) Cache targets | |
id: cache-targets | |
uses: actions/cache@v3 | |
with: | |
path: causal_intro/_targets | |
key: ${{ runner.os }}-targets | |
- name: (Causal intro) Build targets | |
run: targets::tar_make(simulate) | |
shell: Rscript {0} | |
working-directory: causal_intro | |
- name: (Causal intro) Render quarto | |
run: quarto render | |
working-directory: causal_intro | |
- name: Render quarto project | |
uses: quarto-dev/quarto-actions/render@v2 | |
- uses: athenarc/actions-docker-build-push@master | |
id: docker_build | |
with: | |
DOCKER_REGISTRY: "pathos.docker.imsi.athenarc.gr" | |
DOCKER_REPO: "indicator_handbook" | |
DOCKER_USER: "builder" | |
DOCKER_PASSWORD: "${{ secrets.DOCKER_PASSWORD }}" | |
if: github.ref == 'refs/heads/main' | |
- uses: athenarc/actions-docker-compose-deploy@master | |
id: docker_deploy | |
with: | |
AUTH_TOKEN: "${{ secrets.DEPLOY_AUTH_TOKEN }}" | |
USE_PULL_REPO: "false" | |
DEPLOY_URL: "https://delphinus.imsi.athenarc.gr/docker-compose-deploy/deploy" | |
IMAGES: "${{ steps.docker_build.outputs.images }}" | |
if: github.ref == 'refs/heads/main' |