mapbox / ecs-conex

ECS Container Express
32 stars 6 forks source link

"Install docker binary matching EC2 version" (sic) #90

Open yhahn opened 7 years ago

yhahn commented 7 years ago

From https://github.com/mapbox/ecs-conex/blob/master/Dockerfile#L15-L17:

# Install docker binary matching EC2 version
RUN curl -sL https://get.docker.com/builds/Linux/x86_64/docker-1.11.1.tgz > docker-1.11.1.tgz
RUN tar -xzf docker-1.11.1.tgz && cp docker/docker /usr/local/bin/docker && chmod 755 /usr/local/bin/docker

Except the Docker binary on the EC2 is a somewhat moving target. It'll probably be safest if conex enforces version consistency at runtime, checking the docker binaries it's going to run and getting access (Somehow?) to the host's docker version to make sure that the docker binaries within conex are going to talk to a docker service/socket that it's expecting.

cc @mapbox/platform

rclark commented 7 years ago

You're in luck!

》curl -s --unix-socket /var/run/docker.sock http://localhost/info | jq -r .ServerVersion
1.12.6
rclark commented 7 years ago

Note: the new ECS-optimized AMIs bring a newer version of docker. We'll need to upgrade here as well.

cc @vsmart

rclark commented 7 years ago

Related: ECR login through the aws ecr get-login command will now need to include a --no-include-email flag. This is available on the most recent version of awscli.

vsmart commented 7 years ago

For now, @rclark has implemented the option to include multiple docker versions and extract one at runtime here: #103

However, that is still not a stable solution -- updates are required here everytime new versions are released. We're still ☕️ 🤔 of a better way.