Learn R Programming

googleCloudRunner (version 0.2.0)

cr_buildstep_edit: Modify an existing buildstep with new parameters

Description

Useful for editing existing buildsteps

Usage

cr_buildstep_edit(x, ...)

Arguments

x

A buildstep created previously

...

Arguments passed on to cr_buildstep

name

name of docker image to call appended to prefix

args

character vector of arguments

prefix

prefixed to name - set to "" to suppress. Will be suppressed if name starts with gcr.io

entrypoint

change the entrypoint for the docker container

dir

The directory to use, relative to /workspace e.g. /workspace/deploy/

id

Optional id for the step

env

Environment variables for this step. A character vector for each assignment

volumes

volumes to connect and write to

waitFor

Whether to wait for previous buildsteps to complete before running. Default it will wait for previous step.

See Also

Other Cloud Buildsteps: cr_buildstep_bash(), cr_buildstep_decrypt(), cr_buildstep_df(), cr_buildstep_docker(), cr_buildstep_extract(), cr_buildstep_gitsetup(), cr_buildstep_mailgun(), cr_buildstep_nginx_setup(), cr_buildstep_pkgdown(), cr_buildstep_run(), cr_buildstep_r(), cr_buildstep_secret(), cr_buildstep_slack(), cr_buildstep()

Examples

Run this code
# NOT RUN {
package_build <- system.file("cloudbuild/cloudbuild.yaml",
                             package = "googleCloudRunner")
build <- cr_build_make(package_build)
build
cr_buildstep_extract(build, step = 1)
cr_buildstep_extract(build, step = 2)

edit_me <- cr_buildstep_extract(build, step = 2)
cr_buildstep_edit(edit_me, name = "blah")
cr_buildstep_edit(edit_me, name = "gcr.io/blah")
cr_buildstep_edit(edit_me, args = c("blah1","blah2"), dir = "meh")
# }

Run the code above in your browser using DataLab