Skip to content

Commit

Permalink
Update docker commands - see rocker-org/rocker/#50
Browse files Browse the repository at this point in the history
  • Loading branch information
Robinlovelace committed May 22, 2018
1 parent 5c88490 commit a02d3f9
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,9 @@ git clone https://github.com/Robinlovelace/geocompr.git # download the repo
# https://github.com/Robinlovelace/geocompr/archive/master.zip
cd .\geocompr\ # navigate into the repo
# for linux and mac:
docker run -d -p 8787:8787 -v $(pwd):/data robinlovelace/geocompr
docker run -d -p 8787:8787 -v $(pwd):/home/rstudio/data robinlovelace/geocompr
# for windows:
docker run -d -p 8787:8787 -v ${pwd}:/data robinlovelace/geocompr
docker run -d -p 8787:8787 -v ${pwd}:/home/rstudio/data robinlovelace/geocompr
```

If it worked you should be able to open-up RStudio server by opening a browser and navigating to
Expand All @@ -104,12 +104,7 @@ http://localhost:8787/ resulting in an up-to-date version of R and RStudio runni

geocompr in docker: if you see something like this after following the steps above, congratulations: it worked!

From this point to *build* the book you need to navigate to the volume location on docker machine, by opening the project at `/data` from the project box in the top-right hand corner, illustrated in the figure below.
From here open the file `index.Rmd` and hit the little `knit` button above the the RStudio script panel (above the `book` text on line 81 illustrated in the image above).

![](https://user-images.githubusercontent.com/1825120/39538462-d4db2928-4e34-11e8-8612-add5188ed642.png)

Opening the project: navigate to the volume folder in docker (or in another location on your computer)
From this point to *build* the book you can open projects in the `data` directory from the project box in the top-right hand corner, and knit `index.Rmd` with the little `knit` button above the the RStudio script panel (`Ctl+Shift+B` should do the same job).

## Reproducing this README

Expand Down

0 comments on commit a02d3f9

Please sign in to comment.