How to link two docker services in coreos with flannel?

I tried to understand, how to perform a simplest task ever – link two containers running on different coreOS hosts, and failed. As from coreos site documentation, I understood how to simply enable flannel service, but how do you start containers linking each other in systemd services?

Can anybody provide some tutorial where there will be clear even for an idiot steps to start two containers in different coreos virtual machines locally, linked together? Like four simple steps:

  • nginx and php-fpm in Docker
  • echo environment variable with docker run
  • Dockerfile build error when use apt-get install gcc
  • Docker container and memory consumption
  • Register an instance to an AWS ECS cluster
  • Error response from daemon: getsockopt: connection refused
    1. cloud-config (where you enabling flannel)
    2. systemd file for first docker service (say redis)
    3. systemd file for second docker service (say flask, linking redis)
    4. command to start those two up.


  • Permission denied on accessing host directory in docker
  • Docker: device mapper file system gets corrupted
  • Resolving env inside another env
  • Docker Daemon is not working
  • How to avoid copying all the docker context directory?
  • Nginx, AWS, EB, Docker, TCP Socket configuration 400 bad request
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.