ECS
Running ECS tasks on DevZero.
If you're more of a visual learner, check out the video tutorial!
Installation guide
You can run services and tasks managed by AWS ECS inside of DevBoxes using AWS ECS Anywhere.
- Create a new cluster or start with an existing one.
Note: you can only register external nodes after the cluster has been created. - Visit Your Cluster > Infrastructure > Container Instances.
- Click on "Register external instances".
- In the popup, confirm the settings and click on "Generate registration command".
- Copy the command for Linux. You will need it later.
- In your DevZero box, download the installation script for ECS Anywhere:
- Make sure the the downloaded script has the correct permissions:
- Run the installation script with the parameters from the command in step #5:
Note: the installation script will also install Docker.
The new instance should now be visible in the ECS console under Your Cluster > Infrastructure > Container instances as "External" instance type.
Mounting volumes
If you want to add volumes to your services/tasks:
- Go to your Task definition.
- Scroll down to the "Storage" section.
- Click on the "Add volume" button.
- Enter the volume name.
- In "Configuration type", select "Configure at task definition creation".
- Choose "Docker volume" in the "Volume type" section.
- Under "Driver" enter "local" and select "Task" as Scope.
- Create a new container mount point:
Select the container in question, the source volume and enter a mount path.
The new volume should now be available after your task has been created:
If you select "Configure at deployment" in your task definition, you might not be able to deploy it to the external instance type, because this configuration only supports Amazon EBS, which is not available with external instances.
Recipe example
When running tasks/services you should now be able to select "External" launch type in order to run them on your DevBoxes.