The _lambdar.yml
file can be used to customise your container image. Lambdar tries to populate as much information as it can, but if you need to override any options you’re welcome to do so. You can also write your own Dockerfile and use lambdar to build it if you prefer.
aws_account_id
and aws_region
Lambdar uses these when it talks to AWS. This information is needed to:
docker push
and upload your container.If you don’t supply this information you can still build a container if you have Docker installed, or build a Dockerfile if you don’t.
app_name
This is used to name (via docker tag
) your container when it’s built. It also forms part of the ECR repository URL.
r_version
This tells lambdar what version of R to install in your container. Lambdar pre-fills this with your current R version, but you can change it if you need to. Make sure you specify all three digits of the version number, e.g. "3.6.3"
.
r_packages
Any packages listed here will be installed when the container is built. Lambdar will try and determine which packages you need using renv::dependencies()
and will auto-fill this list.
linux_packages
If you need any extra system libraries installing, mention them here. The base AWS image is based on CentOS, so packages will be installed by yum
.
Lambdar can’t work out which Linux package you need so this section is up to you.
env
If your code needs any specific environment variables, enter them here. At the moment yaml
lists are not supported because they don’t translate to the correct data structure in R, so copy the examples in the template.