NASA-IMPACT / covid-api

MIT License
14 stars 3 forks source link

Fix, bump aws-cdk version #151

Open anayeaye opened 1 year ago

anayeaye commented 1 year ago

What

Bump aws-cdk libs from >=1.72.0 to 1.108.0 to resolve AttributeError: module 'aws_cdk.aws_apigatewayv2_integrations' has no attribute 'LambdaProxyIntegration'. Pining the exact version is overkill but versions of the lib >=1.72.0 is not enough to ensure a version with the LambdaProxyIntegration.

How test

To test, follow the build and deployment steps from the circleci yml in a local env. For maintainers in the covid response account, developer aws credentials plus the environment variables stored in the secretsmanager secret named covid-api-env. Example is for staging, can swap in prod.

python3 -m venv .venv
source .venv/bin/activate
pip install -e '.[deploy]'
CDK_DEFAULT_ACCOUNT=<acct> AWS_ACCESS_KEY_ID=<your secret id> AWS_SECRET_ACCESS_KEY=<your key> PLANET_API_KEY=<planet-key> STAGE='staging' cdk deploy covid-api-lambda-staging --region us-east-1