https://github.com/bryaneadams/rstudio-postgres
This is a simple docker-compose.yaml for deploying RStudio with a postgres DB. The intent is to provide an easy way for users to learn how to interact with a DB.
https://github.com/bryaneadams/rstudio-postgres
Last synced: 4 months ago
JSON representation
This is a simple docker-compose.yaml for deploying RStudio with a postgres DB. The intent is to provide an easy way for users to learn how to interact with a DB.
- Host: GitHub
- URL: https://github.com/bryaneadams/rstudio-postgres
- Owner: bryaneadams
- Created: 2021-08-13T00:14:55.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-08-13T00:37:35.000Z (over 3 years ago)
- Last Synced: 2024-08-13T07:13:21.420Z (8 months ago)
- Language: R
- Size: 3.91 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- jimsghstars - bryaneadams/rstudio-postgres - This is a simple docker-compose.yaml for deploying RStudio with a postgres DB. The intent is to provide an easy way for users to learn how to interact with a DB. (R)
README
# Containerized RStudio and PostgreSQL
This is a simple docker-compose.yaml for deploying RStudio with a postgres DB. The intent is to provide an easy way for users to learn how to interact with a DB.
## Getting started
There are two ways to run the services:
### `docker-compose up`
Running `docker-compose up` will use the images found in the [`.env`](.env) file. A volume will be mounted to `/home/rstudio/`.
### `docker-compose -f docker-compose-dev.yaml up`
Running `docker-compose -f docker-compose-dev.yaml up` will build the image using the [`Dockerfile`](Dockerfile) which really just copies the [`r_postgres.R`](r_postgres.R) script into the image for you. The volume is mounted to `/home/rstudio/persistent/`
[`r_postgres.R`](r_postgres.R) provides a very brief overview of using [`DBI`](https://dbi.r-dbi.org)