-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcompose.yml
26 lines (25 loc) · 808 Bytes
/
compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
services:
rstudio:
build:
context: .
dockerfile: Dockerfile
env_file: .env
ports:
- "127.0.0.1:8787:8787"
- "14618:14618"
environment:
DISABLE_AUTH: true
# used only if disable_auth is false
PASSWORD: ${PASSWORD}
volumes:
# configuration files
- ./.rstudio_config:/home/rstudio/.config/rstudio
# project files
- ~/Documents/University/Research_Project/Project:/home/rstudio/workspace
# renv cache
- "${RENV_PATHS_CACHE_HOST}:${RENV_PATHS_CACHE_CONTAINER}"
command: |
sh -c "R -e 'if(file.exists(\"/home/rstudio/workspace/renv.lock\")) { renv::restore(); renv::activate(); } else { print(\"No renv.lock found!\"); };' && /init"
# entrypoint: /usr/bin/tail
stdin_open: true
tty: true