Search code examples
amazon-ec2docker-swarmdocker-machine

AWS - Docker Swarm on 1 EC2 possible (for training)?


Is it possible to create a Docker Swarm on 1 AWS EC2? Of course this is for training purposes.

If possible, what are the steps to create a manager and 2 workers on that 1 EC2?

Can I use the public URL of the AWS to use the docker swarm commands? And the same URL for reaching the docker services / stack items?


Solution

  • It is of course possible to turn Docker Swarm on in a (regular) Docker environment.

    As normal, just use the following command:

    $ docker swarm init

    You will see the default node (as Leader). Now you can move forward using the regular 'docker stack deploy' command.