diff --git a/ecs-service.cfndsl.rb b/ecs-service.cfndsl.rb index 10365a4..b3e357f 100644 --- a/ecs-service.cfndsl.rb +++ b/ecs-service.cfndsl.rb @@ -1,5 +1,7 @@ CloudFormation do + export = defined?(export_name) ? export_name : component_name + awsvpc_enabled = false if defined?(network_mode) && network_mode == 'awsvpc' awsvpc_enabled = true @@ -555,4 +557,9 @@ end + Output("ServiceName") { + Value(FnGetAtt(:Service, :Name)) + Export FnSub("${EnvironmentName}-#{export}-ServiceName") + } + end