An example that deploys Strapi CMS as a containerized web app on AWS with Pulumi.
- Deploys in a VPC (with public and private subnets) with ECS Fargate and Elastic Load Balancing
- Forwards logs to CloudWatch, streams CloudWatch logs to your terminal
- Supports both RDS MySQL and PostgreSQL (with PostgreSQL as the default)
- Stores your media (e.g., Strapi uploads) with Amazon EFS
- Supports custom domains and SSL certs with Route 53 and ACM
- Deploy from your laptop, in CI (e.g., GitHub Actions), or with Pulumi Deployments
- Everything written in TypeScript
More docs to come! 🚀
pulumi new https://github.com/cnunciato/pulumi-strapi
# Install Strapi and Pulumi dependencies.
make ensure
# Develop locally -- build content types, etc. -- using the SQLite backend.
make serve
# Create a new Pulumi stack (e.g., `dev`).
make new-stack
# Deploy!
make deploy
# Browse to your newly deployed Strapi CMS.
make browse
# Stream CloudWatch logs to your terminal.
make logs
# When you're done, tear everything down.
make destroy
See the Makefile
for details.
All configuration settings are optional.
Key | Type | Example | Default |
---|---|---|---|
aws:region |
string |
us-west-2 |
us-west-2 |
dbName |
string |
strapi |
strapi |
dbUsername |
string |
strapi |
strapi |
dbType |
string |
postgres |
postgres |
dbInstanceClass |
string |
db.t3.micro |
db.t3.micro |
dbStorage |
number |
20 |
20 |
dbPassword |
string |
StrongPass1 |
new random.RandomPassword() |
appPort |
number |
1337 |
1337 |
appCPU |
number |
2048 |
2048 |
appMemory |
number |
4096 |
4096 |
appUploadsPath |
string |
public/uploads |
public/uploads |
subdomain |
string |
example.com |
None |
domain |
string |
my-cms |
None |
tags |
object |
{ owner: "yourname" } |
None |