Getting Started

This page tells you how to get started with the Yapawa. What to prepare before installing each service.

Prerequisites

  • AWS Account
  • IAM user with Power user rights
  • AWS CLI
  • AWS CLI named profile
  • nvm
  • NodeJS: nvm install node

Domains

The domains need to be hosted in Route53. Cloudformation will automatically create the relevant Aliases.

You need to define 3 domains. One for each service. To make it easier, it is recommended to use sub-domains. But you don’t have too.

As example:

  • Albums Manager: admin.gallery.example.com
  • Image Resizer: img.gallery.example.com
  • Public Site: gallery.example.com

Hosted Zone ID

Retrieve the HostedZoneId for each domain. You will need to paste it into the configuration files of each service.

HOSTEDZONEID=$(aws --profile myprofile route53 list-hosted-zones --query 'HostedZones[?Name==`example.com.`].Id' --output text | cut -d'/' -f3)

ACM Certificates

ACM Certificates for Cloudfront need to be generated in us-east-1. And since Cloudformation isn’t able to easily do cross region stacks, we will create the certificates manually and only give their ARN as reference to our stacks.

Open ACM in us-east-1, generate a single certificate for gallery.example.com as primary domain and *.gallery.example.com as alternate domain. Use DNS as validation method, click the button to create the entries in Route53.

Keep the ARN (arn:aws:acm:us-east-1:AccountId:certificate/certificateId) somewhere.

Wait for the certificate to be valid.

Amplify

If you haven’t already setup Amplify:

npm install -g @aws-amplify/cli
amplify configure

AWS Region

The services don’t need to be in the same region. But it is highly recommended, mainly for imageResize and publicsite to be in the same region.

Next


Last modified April 21, 2020: Add installation doc (5595b5e)