Easy Swarm

./env.sh cluster  4
Out put:
This will create a swarm master and n number of worker
Need to INIT 
Running pre-create checks...
Creating machine...
docker-machine ls
NAME             ACTIVE   DRIVER       STATE     URL                         SWARM   DOCKER     ERRORS
cluster-1        -        virtualbox   Running   tcp://192.168.99.102:2376           v19.03.4   
cluster-2        -        virtualbox   Running   tcp://192.168.99.103:2376           v19.03.4   
cluster-3        -        virtualbox   Running   tcp://192.168.99.104:2376           v19.03.4   
cluster-4        -        virtualbox   Running   tcp://192.168.99.105:2376           v19.03.4 

Connecting to your cluster

eval $(docker-machine env cluster-1)

Node Status

docker node ls
ID                            HOSTNAME    STATUS  AVAILABILITY        MANAGER STATUS      ENGINE VERSION
vewzxrvrw6ek9ru7qvy8kq22m *   cluster-1   Ready   Active              Leader              19.03.4 
5d90hgsbab78w25jvlrljj3xo     cluster-2   Ready   Active                                  19.03.4 
wb6dkn078hn2wmggcmi7m8ckx     cluster-3   Ready   Active                                  19.03.4 
2pclynemm9cs7dtcgtejbbtxb     cluster-4   Ready   Active                                  19.03.4