stelligent / stelligent_demo

MIT License
6 stars 22 forks source link

migrate Docker from elasticbeanstalk to elastic container service #10

Closed trikosuave closed 9 years ago

trikosuave commented 9 years ago

neither CodeDepoly nor Elastic Container Service have full Cloudformation support yet, so this will need to be added to Patrick's awsome python script

go.py

this will also reduce CFN deploy time, as the bulky substack EB launches will no longer exist

trikosuave commented 9 years ago

Blocked by https://github.com/boto/boto/issues/3205:

try to connect with ecs and get:

In [1]: from boto.ec2containerservice import connect_to_region

In [2]: connect_to_region('us-east-1')
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-2-b2a245438a6c> in <module>()
----> 1 connect_to_region('us-east-1')

/Library/Python/2.7/site-packages/boto/ec2containerservice/__init__.pyc in connect_to_region(region_name, **kw_params)
     36
     37 def connect_to_region(region_name, **kw_params):
---> 38     for region in regions():
     39         if region.name == region_name:
     40             return region.connect(**kw_params)

/Library/Python/2.7/site-packages/boto/ec2containerservice/__init__.pyc in regions()
     31     :return: A list of :class:`boto.regioninfo.RegionInfo`
     32     """
---> 33     from boto.ec2containerservice import EC2ContainerServiceConnection
     34     return get_regions('', connection_cls=EC2ContainerServiceConnection)
     35

ImportError: cannot import name EC2ContainerServiceConnection

Fix is given in issue, but shouldn't have to modify 3rd party libraries. Will keep an eye on this for a patch/new version.

trikosuave commented 9 years ago

we could rewrite demo in other aws supported sdk: (ruby, java, node, and go)

otherwise, for now, we can just shell exec the aws cli, until python boto fixed.

trikosuave commented 9 years ago

CFN now supports ECS for Docker: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/quickref-ecs.html

NickDeClario commented 9 years ago

This has been completed. Everything is in 'cloudformation.ecs.json'. A few changes to get things working. The application inside of Docker is now a static webpage with Stelligent branding hosted by Apache. The docker image gets created at deployment time and added to the local registry which ECS pulls it from. This differs from what is in the documentation; which will get updated.