This is the backend for the deno.land/x service.
- AWS account
- MongoDB Atlas account
- Create a cluster on MongoDB Atlas. A M2 cluster is enough in most cases.
- Create a database user on Atlas. They should have the read write database permission.
- Get the database connection string and insert the username and password for the created. It should look something like this:
mongodb+srv://user:[email protected]/?retryWrites=true&w=majority
. - Save this connection string in AWS Secrets Manager with the name
mongodb/atlas/deno_registry2
and the value keyMongoURI
. - Create a database called
production
in your cluster. - In this database create a collection called
modules
. - In this collection create a new Atlas Search index with the name
default
and the mapping defined inindexes/atlas_search_index_mapping.json
- In this collection create a new index with the name
by_repository
like it is defined inindexes/by_repository.json
- In this collection create a new index with the name
by_star_count
like it is defined inindexes/by_star_count.json
- Install
aws
CLI. - Sign in to
aws
by runningaws configure
- Install AWS
sam
CLI - Run
sam build && sam deploy --guided