Last active
October 5, 2019 12:55
-
-
Save nicor88/d0870cf76fc02d4b89169cb2db801b54 to your computer and use it in GitHub Desktop.
dbt_serverless
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[{ | |
"name": "${container_name}", | |
"image": "${image}:${image_version}", | |
"essential": true, | |
"environment": [ | |
{ | |
"name": "DB_HOST", | |
"value": "${db_host}" | |
}, | |
{ | |
"name": "DB_PORT", | |
"value": "${db_port}" | |
}, | |
{ | |
"name": "DB_USER", | |
"value": "${db_user}" | |
}, | |
{ | |
"name": "DB_PASSWORD", | |
"value": "${db_password}" | |
}, | |
{ | |
"name": "DB_NAME", | |
"value": "${db_name}" | |
}, | |
{ | |
"name": "DB_SCHEMA", | |
"value": "${db_schema}" | |
}], | |
"logConfiguration": { | |
"logDriver": "awslogs", | |
"options": { | |
"awslogs-group": "${log_group}", | |
"awslogs-region": "${log_region}", | |
"awslogs-stream-prefix": "${log_stream_prefix}" | |
} | |
} | |
}] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"StartAt": "first_task", | |
"States": { | |
"first_task": { | |
"Type": "Task", | |
"Resource": "arn:aws:states:::ecs:runTask.sync", | |
"Parameters": { | |
"Cluster": "${ecs_cluster}", | |
"TaskDefinition": "${ecs_task_name}", | |
"LaunchType": "FARGATE", | |
"NetworkConfiguration": { | |
"AwsvpcConfiguration": { | |
"Subnets": ["${subnet_1}", "${subnet_2}", "${subnet_3}"], | |
"AssignPublicIp": "ENABLED", | |
"SecurityGroups": ["${security_group_1}"] | |
} | |
}, | |
"Overrides": { | |
"ContainerOverrides": [ | |
{ | |
"Name": "dbt", | |
"Command.$": "$.commands1" | |
} | |
] | |
} | |
}, | |
"Retry": [ | |
{ | |
"ErrorEquals": ["States.ALL"], | |
"IntervalSeconds": 5, | |
"BackoffRate": 1.5, | |
"MaxAttempts": 3 | |
} | |
], | |
"Catch": [ | |
{ | |
"ErrorEquals": ["States.ALL"], | |
"Next": "FailureNotifier", | |
"ResultPath": null | |
} | |
], | |
"Next": "second_task", | |
"ResultPath": "$.task_1" | |
}, | |
"second_task": { | |
"Type": "Task", | |
"Resource": "arn:aws:states:::ecs:runTask.sync", | |
"Parameters": { | |
"Cluster": "${ecs_cluster}", | |
"TaskDefinition": "${ecs_task_name}", | |
"LaunchType": "FARGATE", | |
"NetworkConfiguration": { | |
"AwsvpcConfiguration": { | |
"Subnets": ["${subnet_1}", "${subnet_2}", "${subnet_3}"], | |
"AssignPublicIp": "ENABLED", | |
"SecurityGroups": ["${security_group_1}"] | |
} | |
}, | |
"Overrides": { | |
"ContainerOverrides": [ | |
{ | |
"Name": "dbt", | |
"Command.$": "$.commands2" | |
} | |
] | |
} | |
}, | |
"Retry": [ | |
{ | |
"ErrorEquals": ["States.ALL"], | |
"IntervalSeconds": 5, | |
"BackoffRate": 1.5, | |
"MaxAttempts": 3 | |
} | |
], | |
"Catch": [ | |
{ | |
"ErrorEquals": ["States.ALL"], | |
"Next": "FailureNotifier", | |
"ResultPath": null | |
} | |
], | |
"ResultPath": "$.task_2", | |
"End": true | |
}, | |
"FailureNotifier": { | |
"Type": "Pass", | |
"Next": "Failure", | |
"ResultPath": "$.notifier" | |
}, | |
"Failure": { | |
"Type": "Fail" | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment