Skip to content

Instantly share code, notes, and snippets.

@AdonousTech
Created January 29, 2021 20:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AdonousTech/1e07e7fdf0a000cb3621b6775b4522d9 to your computer and use it in GitHub Desktop.
Save AdonousTech/1e07e7fdf0a000cb3621b6775b4522d9 to your computer and use it in GitHub Desktop.
A Cloud Coach - Tutorial - Serverless Stripe Store - 019 - CDK LAMBDA NPM Scripts
"build": "tsc",
"update-lambda-code-dev": "npm run build && npm run private-remove-package && npm run private-package-lambda && npm run private-update-lambda-code-dev",
"update-lambda-code-prod": "npm run build && npm run private-remove-package && npm run private-package-lambda && npm run private-update-lambda-code-prod",
"private-update-lambda-code-dev": "aws lambda update-function-code --profile %npm_package_config_devProfile% --region %npm_package_config_region% --function-name %npm_package_config_functionNameDev% --zip-file %npm_package_config_functionFileLocationNormalized%",
"private-update-lambda-code-prod": "aws lambda update-function-code --profile %npm_package_config_prodProfile% --region %npm_package_config_region% --function-name %npm_package_config_functionNameProd% --zip-file %npm_package_config_functionFileLocationNormalized%",
"private-package-lambda": "zip -q -r %npm_package_config_functionFileName% ./lib index.js node_modules",
"private-remove-package": "rm %npm_package_config_functionFileName%"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment