Skip to content

Customize Naming

If you want to modify how the deployer names various resources, you can add a custom section with the following:

For more details on the options you can use in templates, view the Templating documentation.

Danger! Advanced Topic!

Under normal operation you should not need to modify any of these values. Incorrectly modifying the templates used could seriously harm your application and cause downtime.

If you do not understand what these are doing, you should not adjust them

Example Usage

name_templates:
  log_group: "/applogs/{{ .Project }}/{{ .Name }}"

Fields

log_group - (required)

This is the log group path that will be created for each task. This is not used if logging has been disabled.

/ecsdeployer/app/{PROJECT}/{TASK}
/ecsdeployer/app/{PROJECT}/{STAGE}/{TASK}
/ecsdeployer/app/{{ .Project }}/{{ if .Stage }}{{ .Stage }}/{{end}}{{ .Name }}
log_stream_prefix - (required)

Fargate tasks require a logging prefix.

{CONTAINER}
{CONTAINER}
{{ .Container }}
service_name - (required)

The name used for ECS Services. If you need a custom prefix, you can modify this

{PROJECT}-{TASK}
{PROJECT}-{STAGE}-{TASK}
{{ .Project }}{{ if .Stage }}-{{ .Stage }}{{end}}-{{ .Name }}
task_family - (required)

This will be the TaskDefinition Family Name

{PROJECT}-{TASK}
{PROJECT}-{STAGE}-{TASK}
{{ .Project }}{{ if .Stage }}-{{ .Stage }}{{end}}-{{ .Name }}
schedule_group - (required)

The Schedule Group name when creating CronJobs

{PROJECT}
{PROJECT}-{STAGE}
{{ .Project }}{{ if .Stage }}-{{ .Stage }}{{end}}
schedule - (required)

The schedule name when creating CronJobs

ecsd-cron-{PROJECT}-{TASK}
ecsd-cron-{PROJECT}-{STAGE}-{TASK}
ecsd-cron-{{ .Project }}{{ if .Stage }}-{{ .Stage }}{{end}}-{{ .Name }}
cron_group

This is the 'Group' field when a task is run via a cron job. If you have special tracking of this field, you can enter a value here

If you enter something that evaluates to an empty string, then the group field will not be included.

ecsd:{PROJECT}:cron:{TASK}
ecsd:{PROJECT}:{STAGE}:cron:{TASK}
ecsd:{{ .Project }}{{ if .Stage }}:{{ .Stage }}{{end}}:cron:{{ .Name }}
predeploy_group

Same as the cron_group, this is only used when predeploy tasks are run

If you enter something that evaluates to an empty string, then the group field will not be included.

ecsd:{PROJECT}:pd:{TASK}
ecsd:{PROJECT}:{STAGE}:pd:{TASK}
ecsd:{{ .Project }}{{ if .Stage }}:{{ .Stage }}{{end}}:pd:{{ .Name }}
predeploy_started_by

This is the 'StartedBy' field on RunTask.

If you enter something that evaluates to an empty string, then the group field will not be included.

ecsd:{PROJECT}:deployer
ecsd:{PROJECT}:{STAGE}:deployer
ecsd:{{ .Project }}{{ if .Stage }}:{{ .Stage }}{{end}}:deployer
marker_tag_key - (required)

The marker tag is something added to all resources created by the deployer. This allows the deployer to delete resources that it created, but that have since been removed from the deployment configuration file.

Once you deploy a project, you should not modify the values used for the marker tag.

ecsdeployer/project
ecsdeployer/project
ecsdeployer/project
marker_tag_value - (required)

Value used for the tag defined by marker_tag_key

{PROJECT}
{PROJECT}/{STAGE}
{{ .Project }}{{ if .Stage }}/{{ .Stage }}{{end}}