@56k.cloud/cdk-constructs
v0.2.2
Published
TypeScript package that shares CDK constructs to deploy a Next.js web app and Strapi CMS.
Downloads
16,956
Readme
@56k.cloud/cdk-constructs
TypeScript package that shares CDK constructs to deploy a Next.js web app and Strapi CMS.
Installation
npm install @56k.cloud/cdk-constructs
Usage
After creating a ZIP file of your Strapi application and specifying the zipPath
, the Strapi construct will deploy a Strapi app using Elastic Beanstalk. It will also create a PostgreSQL RDS, S3 bucket, VPC and ACM certificates.
new Strapi(this, 'Strapi', {
clientVpnEndpointCertificates: {
serverCertificateArn: 'arn:aws:acm:xxxx:xxxx:certificate/xxxx',
clientCertificateArn: 'arn:aws:acm:xxxx:xxxx:certificate/xxxx'
},
image: EcrImage.fromEcrRepository()
customDomain: {
domainName: 'cms.56k.cloud',
certificate: Certificate
}
environmentVariables: {
key: 'value'
}
})
The Next.js construct will deploy your Next.js app using Open Next and create the ACM certificates if you specify a domain name and a domain alias.
new Nextjs(this, 'Nextjs', {
nextjsPath: '../../apps/www',
customDomain: {
domainName: 'www.56k.cloud',
domainAlias: '56k.cloud',
certificateValidation: CertificateValidation.fromDns()
}
})
This construct will create a CodeBuildRunner
that you can use in your GitHub Actions as a self-hosted runner.
new GithubRunner(this, 'GithubRunner', {
repo: '56kcloud/56kcloud-website',
architecture: Architecture.ARM64
openIdConnectProviderArn: 'arn:aws:iam::XXX:oidc-provider/token.actions.githubusercontent.com'
})