Setup Github

Preparation

First of all, you need to download source code NextJS in this workshop at this link at the folder next-app, you will move it to other folder and push to your repository in the Github. Then you can go next.

Content

  1. In your repository, click “Settings” -> At “Secrets and variables” choose Actions -> “Manage Environment Secrets”
02-github
  1. Click “New Environment” if you don’t have any
03-github
  1. Enter your Environment name and click “Configure environment”
04-github
  1. After that click “Add environment secret”
05-github
  1. You need to add all of your secrets, in this workshop we have

    • AWS_ACCOUNT_ID is in the top right in the AWS Console
    • AWS_REGION ex: ap-southeast-1
    • AWS_S3_ASSUME_ROLE The role name we created before
    • BUCKET_NAME: The bucket name we created
    • CF_DISTRIBUTION_ID: The Cloudfront ID we created
      ex: arn:aws:cloudfront::<YOUR_ACCOUNT_ID>:distribution/<CF_DISTRIBUTION_ID`> <— the cloudfront id here
06-github
  1. Result of all secrets we added
07-github