docker-compose

  • Compose profiles before profiles: two files and a merge

    Wanting the mail catcher and phpMyAdmin locally but not in CI, without maintaining two full compose files, is the problem profiles eventually solve. In 2018 the answer is…

  • Compose file version 3, and what swarm changed

    v3 exists to be deployable to a scheduler, and that removes things a single-host file relied on. What went, why it had to, and what replaces it.

  • Multi-stage builds cut the image in half

    17.05 made the two-Dockerfile trick unnecessary. Named stages, what to copy forward, and why the build cache still rewards the order of instructions.

  • Compose file v3 dropped volumes_from

    A version 2 file could share a container’s volumes with volumes_from, which is how the data-container pattern worked. Version 3 removes it, because a scheduler placing containers on…

  • depends_on does not wait for readiness, and never did

    depends_on controls start order and nothing else. The database container being started is not the database accepting connections, so the application starts, fails to connect, and exits. Version…

  • Docker for Mac replaced the virtual machine

    The shared-folder problem that nearly killed this last year is gone. What changes in the compose file, what the new file sharing costs, and where Linux and Mac…

  • Compose file version 2 moved services under a key

    A version 1 compose file is a bare map of service names. Version 2 nests them under services, which looks like churn and is what makes room for…