Skip to content

Commit

Permalink
Deactivated main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasmalla authored Oct 29, 2024
1 parent 7877060 commit 23721d4
Showing 1 changed file with 51 additions and 51 deletions.
102 changes: 51 additions & 51 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,51 +1,51 @@
name: Deploy Shiny App

on:
push:
branches:
- master # Trigger deployment on push to master branch

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Check out the code
uses: actions/checkout@v3

- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y libcurl4-openssl-dev libssl-dev
- name: Set up R
uses: r-lib/actions/setup-r@v2
with:
r-version: '4.4.1' # Specify the version of R

- name: Install remotes to handle GitHub installations
run: |
Rscript -e 'install.packages("remotes", repos="https://cloud.r-project.org")'
- name: Install required packages
run: |
Rscript -e 'install.packages(c("rms", "Matrix"), repos="https://cloud.r-project.org")'
Rscript -e 'install.packages(c("haven", "shinythemes", "tidyverse", "shiny", "shinydashboard", "shinyWidgets", "lubridate", "stringr", "readxl", "plotly", "zoo", "gridExtra", "cowplot", "anytime", "data.table", "DT", "shinyjs", "flextable", "officer", "ggpubr", "EpiReport", "xlsx", "zscorer", "Hmisc", "survey", "questionr", "writexl", "openxlsx", "readr"),repos="https://cloud.r-project.org", dep=TRUE)'
- name: Install rsconnect from CRAN with logs
run: |
Rscript -e 'install.packages("rsconnect", repos="https://cloud.r-project.org", dependencies = TRUE)'
Rscript -e 'print("rsconnect successfully installed.")'
Rscript -e 'print(sessionInfo())'
- name: Verify rsconnect is installed
run: |
Rscript -e 'if (!"rsconnect" %in% installed.packages()) stop("rsconnect not installed")'
- name: Deploy to shinyapps.io
env:
SHINYAPPS_TOKEN: ${{ secrets.SHINYAPPS_TOKEN }}
SHINYAPPS_SECRET: ${{ secrets.SHINYAPPS_SECRET }}
run: |
Rscript -e 'library(rsconnect)' # Ensure rsconnect is loaded
Rscript -e 'rsconnect::setAccountInfo(name="worldhealthorg", token=Sys.getenv("SHINYAPPS_TOKEN"), secret=Sys.getenv("SHINYAPPS_SECRET"))'
Rscript -e 'rsconnect::deployApp(appFiles=".", appName="GSHS", account="worldhealthorg", forceUpdate=TRUE)'
#name: Deploy Shiny App

#on:
# push:
# branches:
# - master # Trigger deployment on push to master branch

#jobs:
# deploy:
# runs-on: ubuntu-latest

# steps:
# - name: Check out the code
# uses: actions/checkout@v3

# - name: Install system dependencies
# run: |
# sudo apt-get update
# sudo apt-get install -y libcurl4-openssl-dev libssl-dev

# - name: Set up R
# uses: r-lib/actions/setup-r@v2
# with:
# r-version: '4.4.1' # Specify the version of R

# - name: Install remotes to handle GitHub installations
# run: |
# Rscript -e 'install.packages("remotes", repos="https://cloud.r-project.org")'

# - name: Install required packages
# run: |
# Rscript -e 'install.packages(c("rms", "Matrix"), repos="https://cloud.r-project.org")'
# Rscript -e 'install.packages(c("haven", "shinythemes", "tidyverse", "shiny", "shinydashboard", "shinyWidgets", "lubridate", "stringr", "readxl", "plotly", "zoo", "gridExtra", "cowplot", "anytime", "data.table", "DT", "shinyjs", "flextable", "officer", "ggpubr", "EpiReport", "xlsx", "zscorer", "Hmisc", "survey", "questionr", "writexl", "openxlsx", "readr"),repos="https://cloud.r-project.org", dep=TRUE)'

# - name: Install rsconnect from CRAN with logs
# run: |
# Rscript -e 'install.packages("rsconnect", repos="https://cloud.r-project.org", dependencies = TRUE)'
# Rscript -e 'print("rsconnect successfully installed.")'
# Rscript -e 'print(sessionInfo())'
# - name: Verify rsconnect is installed
# run: |
# Rscript -e 'if (!"rsconnect" %in% installed.packages()) stop("rsconnect not installed")'

# - name: Deploy to shinyapps.io
# env:
# SHINYAPPS_TOKEN: ${{ secrets.SHINYAPPS_TOKEN }}
# SHINYAPPS_SECRET: ${{ secrets.SHINYAPPS_SECRET }}
# run: |
# Rscript -e 'library(rsconnect)' # Ensure rsconnect is loaded
# Rscript -e 'rsconnect::setAccountInfo(name="worldhealthorg", token=Sys.getenv("SHINYAPPS_TOKEN"), secret=Sys.getenv("SHINYAPPS_SECRET"))'
# Rscript -e 'rsconnect::deployApp(appFiles=".", appName="GSHS", account="worldhealthorg", forceUpdate=TRUE)'

0 comments on commit 23721d4

Please sign in to comment.