-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
88 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
*.d.ts | ||
node_modules | ||
package-lock.json | ||
.env | ||
*.env | ||
backup.env | ||
.ipynb_checkpoints | ||
SimpleServer.ipynb | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
sam package --s3-bucket scratch-cheetsheet-deployment --debug | ||
sam deploy --stack-name sam-app \ | ||
--parameter-overrides LayerArn=$LAMBDA_LAYER \ | ||
--s3-prefix deploy --s3-bucket scratch-cheetsheet-deployment --debug \ | ||
--region $AWS_DEFAULT_REGION --capabilities CAPABILITY_IAM |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# ------------------------------------------------------------------------------ | ||
# CODE DOCKER COMPOSE | ||
# | ||
# This Docker Compose is meant to deploy frontend code and backend code | ||
# to a remote environment. | ||
# | ||
# What this deploys: | ||
# - Angular code to an S3 bucket | ||
# - Lambda Function that connects to an API Gateway | ||
# | ||
# Prerequisites: | ||
# - Cognito Userpool | ||
# - API Gateway | ||
# - S3 Bucket for UI hosting | ||
# - S3 Bucket for App Data Storage | ||
# | ||
# ------------------------------------------------------------------------------ | ||
version: '3.7' | ||
services: | ||
# -------------------------------------------------------------------------- | ||
# FRONTEND WRITTEN IN ANGULAR | ||
# -------------------------------------------------------------------------- | ||
serverless-angular-client-ui: | ||
build: ./client-ui | ||
container_name: serverless-angular-client-ui | ||
volumes: | ||
- ./client-ui:/usr/src/app | ||
- /usr/src/app/node_modules | ||
command: sh deploy.sh | ||
# -------------------------------------------------------------------------- | ||
# BACKEND WRITTEN IN AWS SAM LOCAL | ||
# -------------------------------------------------------------------------- | ||
serverless-lambda-api: | ||
build: ./api | ||
container_name: serverless-lambda-api | ||
volumes: | ||
- ./api:/app | ||
environment: | ||
- AWS_DEFAULT_REGION=$AWS_DEFAULT_REGION | ||
- AWS_ACCESS_KEY_ID=$AWS_ACCESS_KEY_ID | ||
- AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY | ||
- LAMBDA_LAYER:$LAMBDA_LAYER | ||
# command: bash deploy.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# ------------------------------------------------------------------------------ | ||
# INFRASTRUCTURE DOCKER COMPOSE | ||
# | ||
# This Docker Compose is meant provision the necessary AWS resources | ||
# for a user. This includes VPC's, Subnets, Roles and Policies. | ||
# | ||
# What this sets up: | ||
# - Cognito Userpool | ||
# - API Gateway | ||
# - S3 Bucket for UI hosting | ||
# - S3 Bucket for App Data Storage | ||
# - S3 Bucket for Code Deployment Artifacts | ||
# | ||
# Prerequisites: | ||
# - AWS VPC | ||
# - Route53 Domains | ||
# - Cloud Front CDN | ||
# | ||
# Note: If you don't have a Cloud Admin who can set this up for you | ||
# it is recommended to use docker-compose.network.yml | ||
# ------------------------------------------------------------------------------ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# ------------------------------------------------------------------------------ | ||
# NETWORK DOCKER COMPOSE | ||
# | ||
# This Docker Compose is meant to setup the necessary network infrastructure | ||
# for the app. This includes VPC's, Subnets, Roles and Policies. | ||
# ------------------------------------------------------------------------------ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters