Docker container image on AWS

The advantage of using docker based container is to get performance benefit by avoiding Hipervisor layer. But when we deploy docker based image on AWS EC2 instances, what is the use? Amazon EC2 instances are running on Hipervisor layer only.

  • Q1. We dont get much benefit when deployed on AWS?
  • Q2. If Q1 is true, then we have to go for On-Premise solutions if we use Docker image?

Please clarify. Thank you.

  • docker-compose got error when bringing up nodejs application docker container
  • can't build python docker image
  • Docker image not exposing
  • How start docker container with specific veth pair name
  • docker notary : tls: oversized record received with length 20527
  • Connect to database in docker container on remote host with pgadmin3
  • Create Docker container from image without starting it
  • Run multi mysql services on same machine
  • HTTPS request from Docker container to LAN IP fails, but curl works
  • How to keep ubuntu image running?
  • php:5.6-apache Docker gives empty response on macos
  • Can I mount host directory contents to container directory?
  • 2 Solutions collect form web for “Docker container image on AWS”

    You’re not considering the benefits of packaging your application as a docker container image. Once the image has been pushed to an accessible Docker registry you can run it on any compatible server where Docker is installed.

    Each Docker container is an specially isolated process running on the host server. Whether the host is a virtual machine or physical server is an implementation detail.

    Hope this helps

    The initial statement is false. Docker container still relies on OS functionality. Performance is never the selling point of docker : if you want bare bone performance, you can use assembly language and write your own stuff from scratch. Docker benefit is all about ease of deployment of your application ASAP without trouble and scale, it does not “get performance benefit”.

    Because of the flaw statement, question 1 is flawed.

    The benefit of using AWS EC2 or EC2 container services is flexibility on scaling your needs, i.e. from T2.micro to multiple system using ELB , spot instance, redundancy, etc.

    You can keep arguing about co-location/on-Premise box “performance benefit”, but you can’t change the box without incurred additional cost. For bare-bone machine, you must over provisioned the box, pay for all those cost upfront with your best guess.

    For example, ECS c4.2xlarge (8 vCPU, 15GB RAM) may not perform as good as your over provisioned i7 16GB on-premises box for 3 years ahead. Say fact, in the beginning, c4.large (2vCPU, 3.75GB RAM) is enough for the first 6 months. In AWS, you just take the C4.large instance instead of over provisioned.

    And after 6 months, your over-provisioned on-premises box face periodically spikes, you can’t do anything unless you procure an upgrade. For AWS, you have many options, e.g.

    1. Just restart the VM instance to better type c4.4xlarge or m4 if it is RAM intensive than cpu intensive. And/OR
    2. Enable ECS/EC2 auto-scaling. AND/OR
    3. Use Spot fleet and spot-fleet scaling AND/OR
    4. Extend to other AWS services, e.g. RDS, lambda, etc. AND/OR
    5. You can terminate the instances any time. (If you decides to stop the project)

    You should use on-premises , if

    1. You foreseen no future hardware growth
    2. Your on-premises hardware + co-location + maintenance cost(backup ,etc) is cheaper than the annual AWS fees and you intent to run it for at least 1 year
    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.