Note: This action is designed for use within Perx Health's infrastructure... it might not be very useful for other scenarios!
This repository contains a GitHub Action allowing you to deploy new builds to AWS ECS by creating a new Task Definition and Task from said definition.
As an example, add the following step
to a GitHub Actions workflow.
- name: π Deploy QA
uses: perxhealth/aws-ecs-deploy-action@v1
with:
perx_env: qa
perx_region: au
perx_app_name: behavioural-science-hacks
image_tag: latest
The Action currently expects some required inputs and some optional inputs.
NOTE: Input names are snake_case, not kebab-case.
-
perx_env
Name of the Perx Environment which the deploy will target.
-
perx_region
Name of the Perx Region, representing locations on Earth and data sovereignty boundaries where the deploy will live.
-
perx_app_name
Name of the application/service itself. This is expected to match the application/service's cluster/runner naming convention.
-
image_tag
Append a tag to the image name before pushing. This is not optional as we do not recommend encouraging a default of
latest
.
-
perx_db_env
If the application connects to a database, nominate the environment from which credentials are pulled
-
image_name
Explicitly nominate the image's name (excluding tag) instead of inferring from
perx_app_name
The Action currently produces no outputs.
The Action currently expects AWS credentials to exist in the environment, with sufficient permissions to perform the following actions.
DescribeTasks
RegisterTaskDefinition
RunTask
As this is a Docker based action which uses bash scripts to do its job, there is not any specific development steps to follow.
If you wish to contribute, open up action/entrypoint.sh
and get clacking!
Visit this page to get instructions on how to install Docker, if you haven't already
$ git clone [email protected]:perxhealth/aws-ecs-deploy-action.git
$ cd aws-ecs-deploy-action
At the time of writing, there's no test suite to run.