Skip to content

shuty-dev/aws_cdk_py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aws_cdk_py

How to start server

$ docker-compose build
$ docker-compose up -d
$ docker exec -it ContainerID /bin/bash

For Developer

  • after login shell
    • install python modules at cdk/setup.py
    • setup aws cli(devlopment, staging, production)
  • [Caution]
    • Scripts(aws cli) are dependent at .env
$ ./setup.sh
  • if does not work, you must be check permissions(setup.sh)
$ chmod 755 setup.sh

Activating the Virtualenv

  • To activate your virtualenv on a Linux or MacOs platform:
$ source .env/bin/activate
  • install the required python modules.
$ pip install --upgrade pip && pip install -r requirements.txt

Learn Project Structure

Synthesize a template from app

  • This will output the following CloudFormation template:
$ cdk [--profile PROFILE] synth -c env=ENV

Command List (ja-blog)

Bootstrapping an environment

  • The first time you deploy an AWS CDK app into an environment (account/region)
  • need to install a bootstrap stack
$ cdk [--profile PROFILE] bootstrap -c env=ENV

How to deploy

$ cdk [--profile PROFILE] deploy STACK_NAME -c env=ENV

Handling Context at cdk.json

Context 値は AWS CDK が自動で生成して使い回すものもあるし、開発者が明示的に保管しておく値もある

Check Software Version

$ aws --version
$ cdk --version

Setup aws configure

$ aws configure

Check Profile

$ cat ~/.aws/credentials
$ cat ~/.aws/config
$ aws configure list

Show env var

# List
$ printenv

# Var
$ echo $VAR

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published