title: Docker links with awsvpc network mode
body: <p>I have a Java webapp deployed in ECS using the tomcat:8.5-jre8-alpine image. The network mode for this task is awsvpc; I have many of these tasks running across 3 EC2 instances fronted by an ALB.</p>
  
  <p>This is working fine but now I want to add an nginx reverse-proxy in front of each tomcat container, similar to this example: <a href="https://github.com/awslabs/ecs-nginx-reverse-proxy/tree/master/reverse-proxy" rel="nofollow noreferrer">https://github.com/awslabs/ecs-nginx-reverse-proxy/tree/master/reverse-proxy</a>.</p>
  
  <p>My abbreviated container definition file is:</p>
  
  <pre><code>{
      "containerDefinitions": [
       {
         "name": "nginx",
         "image": "&lt;NGINX reverse proxy image URL&gt;",
         "memory": "256",
         "cpu": "256",
         "essential": true,
         "portMappings": [
           {
             "containerPort": "80",
             "protocol": "tcp"
           }
         ],
         "links": [
           "app"
         ]
       },
       {
         "name": "app",
         "image": "&lt;app image URL&gt;",
         "memory": "1024",
         "cpu": "1024",
         "essential": true
       }
      ],
      "volumes": [],
      "networkMode": "awsvpc",
      "placementConstraints": [],
      "family": "application-stack"
  }
  </code></pre>
  
  <p>When I try to save a new task definition I received the error: "links are not supported when the network type is awsvpc"</p>
  
  <p>I am using the awsvpc network mode because it gives me granular control over the inbound traffic via a security group.</p>
  
  <p>Is there any way to create a task definition with 2 linked containers when using awsvpc network mode?</p>