What did you do this past week?
Last week, I met with the team to discuss and distribute work on the project. We got most of the data in, as well as the player profile links. The site is looking more and more complete with the passing of every day, we just need to polish the frontend a bit.
What’s in your way?
I recently started Stranger Things. Bad idea.
What will you do next week?
Next week, we will be getting together to discuss the frontend and what needs to be done there. The technical reports needs to be updated, and the data still needs some missing relations that I will be working on.
What’s my experience of the class?
Great so far.
What’s my pick-of-the-week or tip-of-the-week?
My past couple of weeks’ blogs focused on Docker related information. This week won’t be any different, only this time I will be talking about Docker Swarm. One of the main benefits of using Docker is the ease of scaling and replication. A container is just an instance of an image, and as a result, you can create many containers from a single image. With Docker Swarm, these containers can run on completely different hosts and be able to communicate as if they were within the same network. The benefits of this are countless considering the need for 99%+ up-time on today’s sites and applications.
To get started, you will need at least 3 machines (or vms for testing). On one of the machines, type
docker swarm init --advertise-addr MACHINE-IP. This will initialize the swarm with the manager set as the machine you chose. In the output of the above command, you will see a token, copy it down since you will need it to join the swarm from the other machines. Next, login to the second and third machines then execute
docker swarm join --token TOKEN. You are now connected to the swarm and the machines are able to communicate with each other. If one of the workers goes down, the replication to the other workers should allow your application to remain online, if the manager goes down, the workers will take a vote to decide on who the new manager should be and your application should remain online.