ecs-deplojo icon indicating copy to clipboard operation
ecs-deplojo copied to clipboard

Support for non-multiple-accounts infrastructure

Open robmoorman opened this issue 8 years ago • 2 comments

Some facts as I experience most of the projects I work on:

  1. Most of projects are setup secure by having their own aws account (e.g. test and production separated).
  2. Also in almost every case the infrastructure for test is the same for production, only smaller instance sizes and/or desired counts to minimize capacity

When having an AWS account where you have multiple environments setup in, the task definition names will conflict with each other.

A suggestion, make the configuration more abstract:

---
clusters:
  test:
    test-example
  production:
    production-example

environments:
    test:
      DATABASE_URL: postgresql://
    production:
      DATABASE_URL: postgresql://

task_definitions:
  web: 
    template: task_definitions/web.json
    overrides:
      production:
        memory: 512

services:
  web: 
    task_definition: web

before_deploy:
  - task_definition: manage
    container: uwsgi
    command: manage.py migrate --noinput

Deploy with e.g. ecs-deplojo --config example.yaml --env production --var="image=example:latest"

robmoorman avatar Mar 21 '17 12:03 robmoorman

This would result in quite large config files (for some of our projects > 400 lines) Need to think about this a bit more

mvantellingen avatar Apr 14 '17 14:04 mvantellingen

I'd think you could always generate a config file on the fly with templating.

jasiek avatar May 27 '21 07:05 jasiek