Advertisement
Guest User

Untitled

a guest
Jul 22nd, 2019
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.25 KB | None | 0 0
  1. ############################################################
  2. # AWS ECS-TASK
  3. ############################################################
  4.  
  5. resource "aws_ecs_task_definition" "task_definition" {
  6. container_definitions = "${data.template_file.task_definition_json.rendered}" # task defination json file location
  7. execution_role_arn = "EcsTaskExecutionRole" #CHANGE THIS # role for executing task
  8. family = "openapi-task-defination" # task name
  9. network_mode = "awsvpc" # network mode awsvpc, brigde
  10. memory = "2048"
  11. cpu = "1024"
  12. requires_compatibilities = ["EC2"] # Fargate or EC2
  13. task_role_arn = "EcsTaskExecutionRole" #CHANGE THIS # TASK running role
  14. }
  15.  
  16. data "template_file" "task_definition_json" {
  17. template = "${file("${path.module}/task_definition.json")}"
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement