Updated packages #375
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
# Trying marketplace deploy action: | |
# https://github.com/marketplace/actions/deploy-to-shinyapps-io | |
name: Deploy to shinyapps.io | |
on: | |
push: | |
branches: | |
- main | |
- development | |
workflow_dispatch: | |
jobs: | |
deploy: | |
name: Deploy to shinyapps | |
# allow skipping deployment for commits containing '[automated]' or '[no-deploy]' in the commit message | |
if: "!contains(github.event.head_commit.message, '[automated]') && !contains(github.event.head_commit.message, '[no-deploy]')" | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set env vars (dev) | |
if: endsWith(github.ref, '/development') | |
run: | | |
echo "SHINYAPP_NAME='local-skills-dashboard-preprod'" >> $GITHUB_ENV | |
- name: Set env vars (prod) | |
if: endsWith(github.ref, '/main') | |
run: | | |
echo "SHINYAPP_NAME='local-skills-dashboard'">> $GITHUB_ENV | |
- name: Install dependencies | |
run: | | |
sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable | |
sudo apt-get update | |
sudo apt-get install libgdal-dev libgeos-dev libproj-dev | |
pip install GDAL==3.6.2 | |
which gdal-config | |
- name: Check system path | |
shell: Rscript {0} | |
run: | | |
cat(Sys.getenv('PATH')) | |
Sys.setenv(PATH=paste("/usr/bin/", Sys.getenv("PATH"), sep=";")) | |
cat(Sys.getenv('PATH')) | |
- name: Check system path 2 | |
run: > | |
Rscript | |
-e "cat(Sys.getenv('PATH'))" | |
- name: deploy | |
uses: BDSI-Utwente/shinyapps-deploy-github-action@v1 | |
with: | |
# account and application name (https://<accountName>.shinyapps.io/<appName>) | |
appName: ${{env.SHINYAPP_NAME}} | |
accountName: 'department-for-education' | |
# token and secret obtained from https://www.shinyapps.io/admin/#/tokens | |
accountToken: ${{ secrets.SHINYAPPS_TOKEN }} | |
accountSecret: ${{ secrets.SHINYAPPS_SECRET }} | |