This is a Next.js template for a twitter-like micro-blogging website.
This template is designed to be hosted easily on Vercel and AWS.
Go to AWS and log in or create a new account.
Create a new IAM role with programmatic access and the permission policies AmazonDynamoDBFullAccess
and AmazonS3FullAccess
Add the ACCESS_KEY
and SECRET_KEY
to the environment variables
Add your AWS region to the env variables as REGION
Head to AWS DynamoDB and create a new database with the Partition key id
(String) and a Sort key createdAt
(Number) and add the table name as environment variable TABLE_NAME
Create a new S3 Bucket on AWS, make it public and enable ACLs.
Add the S3 Bucket name as S3_BUCKET
to the env variables.
Define the variables NEXTAUTH_URL
(your domain eg. http://localhost:3000
for local testing) and NEXTAUTH_SECRET
- more info about this in the next-auth library.
Add your admin account to the env variables with ADMIN_USERNAME=admin
and ADMIN_PASSWORD=some-password
.
Install dependencies with npm i
and run the app with npm run dev
Use following URL to log into your admin account: http://localhost:3000/api/auth/signin
created by Vincent Will