Semaphore fully supports continuous integration and deployment with Docker. Docker's container technology can be used in various use cases. You can learn more about these use cases in the official Docker documentation.
To start using Docker tools, switch your Semaphore project to using the Docker platform under Project Settings > Platform.
Semaphore's Docker platform has Docker 17.06, docker-machine 0.8.2, and docker-compose 1.14.0 pre-installed, so you'll be ready to use the Docker CLI once you've made the switch in your build commands.
To avoid including the project's dependency cache in Docker's build context, add .semaphore-cache to the dockerignore file in your repository. This step is done automatically when you use docker-cache.
Docker images can be cached using the included docker-cache tool. Add docker-cache restore to your project's setup commands to load the cached images. Images can be saved by adding docker-cache snapshot as an after job command. Note that only tagged images will be stored.
To learn more about using Docker, please consult the following guides:
If you have questions about using Docker that are not covered here, please contact us.
Semaphore Docs are open source — Edit on GitHub