Docker Swarm discovery is still relevant?

i’m learning about docker swarm, and got confused about the swarm discovery option, i see that lots of tutorials on internet use this option to create containers with docker-machine, but when i enter the documentation on docker swarm doc it says:

You are viewing docs for legacy standalone Swarm. These topics describe standalone Docker Swarm. In Docker 1.12 and higher, Swarm mode is integrated with Docker Engine. Most users should use integrated Swarm mode.

  • Need for service discovery for docker engine swarm mode
  • How to set up autoscaling RabbitMQ Cluster AWS
  • What is the difference between exposing docker port and creating bridge(or overlay)?
  • How to deal with stale data when doing service discovery with etcd on CoreOS?
  • DC/OS on top of a docker container cluster
  • What is the concept of Ambassador in distributed systems?
  • So, what are the use cases for the discovery options? All the tutorials use the docker-machine to create a swarm, i always need it or can just install the docker on machines in my cluster, join them in swarm and use normal?

    I saw some names like Docker Swarm and Docker Swarm Mode, are there any difference or just different ways to call the same feature?

  • Trying to reach localhost from inside Selenium docker
  • Docker daemon wont start , do i need something configuration before?
  • What is a good tool for geo-distributed docker management
  • bluemix “docker images” results in “json: cannot unmarshal string into Go value of type int”
  • What does volume_from do if there are no volumes in the volume container?
  • How can I structure my docker projects for easy deployment?
  • One Solution collect form web for “Docker Swarm discovery is still relevant?”

    Q. Docker Swarm discovery is still relevant?

    A: No, if you use docker Swarm Mode and an overlay network (see below)

    Q. Are there any difference between Docker Swarm and Docker Swarm Mode?

    A: Yes, TL;DR Docker Swarm is deprecated and should not be used anymore, Docker Swarm Mode (we should just say Swarm Mode) is the recommended way of clustering containers and have reliability, load-balancing, scaling, and rolling service upgrades.

    Docker Swarm (official doc) :

    • is the old fashioned way (<1.12) of clustering containers
    • uses a dedicated container for building a Docker Swarm cluster
    • needs a discovery service like Consul to reference containers in cluster

    Swarm Mode (official doc):

    • is the new and recommended way (>=1.12) of clustering containers on host nodes (called managers / workers)
    • is built-in in Docker engine, you don’t need an additional container
    • has a built-in discovery service if you use an overlay network (DNS resolution is done within this network), you don’t need an additional container

    You can have a look to this SO thread on same topic.

    Q. Do i always need docker-machine to create a swarm?

    A: No, docker-machine is a helper to create virtual hosts in the cloud like amazon ec2, azure, digitalocean, google, openstack…, or your own network with virtual box.

    To create a Swarm Mode, you need :

    • a multiple hosts cluster with docker engine installed on each host (called node) (that is what docker-machine facilitates)
    • run docker swarm init to switch to Swarm Mode on your first manager node
    • run docker swarm join on worker nodes to add them in the cluster

    There are some subtle adjustments to Swarm mode to increase high availability (recommended number of managers in the swarm, node placement in multiple availability zones in the cloud)

    Hope this helps!

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.