This guide provides instructions for deploying Cohere’s Toolkit on AWS using AWS Copilot. AWS Copilot is a CLI tool that simplifies building, releasing, and managing production-ready applications on Amazon ECS with AWS Fargate.
AdministratorAccess
policy enabled.Before starting, ensure you have:
aws configure
to set up your AWS Access Key ID
, Secret Access Key
, region
, and output format
.env
, configuration.yaml
, and secrets.yaml
:
AdministratorAccess
, select it, and proceed with Next.Other
, and proceed.Access key
and Secret access key
and store them securely.aws configure
and input the Access key
, Secret access key
, region
, and output format
.The deployment script uses configuration values from either the .env or configuration.yaml file. Set the following environment variable in the .env file:
DATABASE_URL='postgresql+psycopg2://postgres:postgres@{service name}.{env name}.{app name}.local:5432'
Or, in the configuration.yaml file::
database:
url: postgresql+psycopg2://postgres:postgres@{service name}.{env name}.{app name}.local:5432
For the current deployment, the database URL should be:
postgresql+psycopg2://postgres:postgres@toolkit-app-db.dev.toolkit-app.local:5432
./aws_copilot_deploy/aws_deploy.sh
./aws_copilot_deploy/aws_cleanup.sh
The provided deployment script uses AWS Copilot to set up an application, environment, and services on AWS Fargate. This deployment includes:
copilot storage init
.cpu
, memory
) in each service’s manifest.yml
file as needed.aws_deploy.sh
or delete a service with:
copilot svc delete
Refer to the full AWS Copilot documentation for more commands.