Skip to content

Commit

Permalink
And cron start (#28) and start Docker build instance (#32)
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkEdmondson1234 committed Feb 17, 2017
1 parent 15df2d3 commit ef10488
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 1 deletion.
2 changes: 1 addition & 1 deletion R/container.R
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ gce_vm_container <- function(file = NULL,
#' This will only work on the Google Container optimised containers of image_family google_containers.
#' Otherwise you will need to get a container authentication yourself (for now)
#'
#' It will start the push but it may take a long time to finish, espeically the first time,
#' It will start the push but it may take a long time to finish, especially the first time,
#' this function will return whilst waiting but don't turn off the VM until its finished.
#' @return The tag the image was tagged with on GCE
#' @export
Expand Down
1 change: 1 addition & 0 deletions inst/cloudconfig/opencpu.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ write_files:
--name=opencpu-server \
%s
ExecStop=/usr/bin/docker stop opencpu
ExecStopPost=/usr/bin/docker rm opencpu
runcmd:
- systemctl daemon-reload
Expand Down
1 change: 1 addition & 0 deletions inst/cloudconfig/r-base.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ write_files:
--net=host \
%s
ExecStop=/usr/bin/docker stop r-base
ExecStopPost=/usr/bin/docker rm r-base
runcmd:
- systemctl daemon-reload
Expand Down
1 change: 1 addition & 0 deletions inst/cloudconfig/shiny.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ write_files:
-v /home/gcer/library/:/library/ \
%s
ExecStop=/usr/bin/docker stop shiny
ExecStopPost=/usr/bin/docker rm shiny
runcmd:
- systemctl daemon-reload
Expand Down
17 changes: 17 additions & 0 deletions inst/dockerfiles/googleComputeEngineR-worker/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM rocker/verse
MAINTAINER Mark Edmondson ([email protected])

# install R package dependencies
RUN apt-get update && apt-get install -y \
## clean up
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/ \
&& rm -rf /tmp/downloaded_packages/ /tmp/*.rds

## Install packages from CRAN
RUN install2.r --error \
-r 'http://cran.rstudio.com' \
googleComputeEngineR \
## install Github packages
## clean up
&& rm -rf /tmp/downloaded_packages/ /tmp/*.rds \
3 changes: 3 additions & 0 deletions inst/dockerfiles/hadleyverse-crontab/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ RUN install2.r --error \
&& Rscript -e "devtools::install_github(c('bnosac/cronR'))" \
## clean up
&& rm -rf /tmp/downloaded_packages/ /tmp/*.rds \

## Start cron
RUN service cron start

0 comments on commit ef10488

Please sign in to comment.