Configuration

Blimp is a drop-in replacement for Docker Compose that uses standard Docker Compose files for configuration. See the Docker Compose documentation for more on how to write Docker Compose files.

While there are some differences between Blimp and Docker Compose, the majority of docker-compose.yaml files will work unchanged.

Example

The following docker-compose.yaml file will work with both docker-compose up and blimp up

version: '3'
services:

  # The name of the service.
  web:

    # The path to the Docker build context.
    build: .

    # An alternate Dockerfile can also be specified with a map.
    # build:
    #  dockerfile: Dockerfile.dev
    #  context: .

    command:
      - "node"
      - "/usr/src/app/server.js"

    # Set environment variables.
    environment:
      NODE_ENV: "development"

    # The ports to forward from the container to `localhost`.
    # Accessing `localhost:8080` on your machine will hit `8080`
    # within the container.
    ports:
      - "8080:8080"

    depends_on:
      - mongo

    volumes:
      # Sync ./app to /usr/src/app/app in the container.
      - ./app:/usr/src/app/app

      # Named volumes are also supported.
      - data:/data

  mongo:
    image: "mongo"
    ports:
      - "27017:27017"

# Declare named volumes here.
volumes:
  data: