Services are separate containers that run alongside your Pipelines. Examples of services are testing databases and message queues. You specify service containers in your wercker.yml file through the
services: - mongo
Having multiple services is also possible:
services: - mongo - redis
Tags specify a version of your service container:
services: - mongo:2.2.7
Please check the documentation of the container you are using if additional environment variables need to be injected in the container or not.
Note that as opposed to the box section, which is a singular item, the services section contains a list of items and as such is preceded by a
Optionally you can provide each server with a unique name, which allows you to use multiple services with the same image:
services: - name: red1 id: sutoiku/redis cmd: redis-server - name: red2 id: sutoiku/redis cmd: redis-server
This will override the Docker
name, which in turn is the hostname for that container.
To understand how to connect to these services, please see Service Container Networking