Skip to content

Add docker to containers #16

@grayside

Description

@grayside

Problem

It is not currently possible to run docker in our build scripts.

This would facilitate:

  1. Using tools via containers instead of installing into the workspace environment.
  2. Running unit tests and system tests inside containers for container-based samples such as those for Cloud Run or GAE Flex.

Solution

The trampoline runnings our testing containers with the necessary flags for docker-in-docker, so the blocker is adding the docker client to our container images.

This can be done relatively simply. For example, if we wanted to use Docker version 17.12 (old, but consistent with how cloud-sdk-docker container:

FROM docker:17.12.0-ce as static-docker-source
# Later, inside our existing container stage:
COPY --from=static-docker-source /usr/local/bin/docker /usr/local/bin/docker

The latest stable docker binary in the official docker image is 48.4 MB.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions