-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into add_app_files
- Loading branch information
Showing
9 changed files
with
51 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ENV=prod |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ENV=dev |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,22 @@ | ||
source("renv/activate.R") | ||
try(source("renv/activate.R")) | ||
|
||
cat(" | ||
-------------------------------------------------------------------------------- | ||
Welcome to the iAtlas Shiny App | ||
-------------------------------------------------------------------------------- | ||
\n") | ||
|
||
if (Sys.getenv("DOCKERBUILD") == "1") { | ||
try(renv::restore()) | ||
try(startup::startup()) | ||
local({ | ||
options(shiny.port = 3838, shiny.host = "0.0.0.0") | ||
}) | ||
} else if (length(find.package("devtools", quiet=T)) == 0 || length(find.package("renv", quiet=T)) == 0) { | ||
# prompt instead since RStudio won't show progress for slow .RProfile scripts... | ||
cat("TODO: Install package requirements. This may take up to an hour the first time.\n") | ||
cat("RUN: source('./install.R')\n") | ||
} else { | ||
# auto-run since it should be quick, but makes sure any new requirements are installed. | ||
source('./install.R') | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
DB_NAME <- Sys.getenv("DB_NAME", unset = "iatlas_shiny_dev") | ||
DB_HOST <- Sys.getenv("DB_HOST", unset = "localhost") | ||
DB_PORT <- Sys.getenv("DB_PORT", unset = "5432") | ||
DB_USER <- Sys.getenv("DB_USER", unset = "postgres") | ||
DB_PW <- Sys.getenv("DB_PW", unset = "docker") |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
DB_NAME <- Sys.getenv("DB_NAME", unset = "") | ||
DB_HOST <- Sys.getenv("DB_HOST", unset = "") | ||
DB_PORT <- Sys.getenv("DB_PORT", unset = "") | ||
DB_USER <- Sys.getenv("DB_USER", unset = "") | ||
DB_PW <- Sys.getenv("DB_PW", unset = "") |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
DB_NAME <- Sys.getenv("DB_NAME", unset = "iatlas_shiny_test") | ||
DB_HOST <- Sys.getenv("DB_HOST", unset = "localhost") | ||
DB_PORT <- Sys.getenv("DB_PORT", unset = "5432") | ||
DB_USER <- Sys.getenv("DB_USER", unset = "postgres") | ||
DB_PW <- Sys.getenv("DB_PW", unset = "docker") |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
try(startup::startup()) | ||
cat(crayon::blue("SUCCESS: iatlas.app is ready to go.\n")) | ||
cat(crayon::blue(paste0("RUN: ",crayon::bold("shiny::runApp()\n")))) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
renv::restore(confirm=FALSE) | ||
source('./init.R') |
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