- deploy:dev: deploy to the AWS dev environment
- deploy:prod: deploy to the AWS prod environment
- deploy:local: start local development environment
Read this https://github.com/DieProduktMacher/serverless-env-generator
Use the following commands to read and decrypt variables from your YAML environment files:
serverless env
serverless env --stage $STAGE
serverless env --attribute $NAME
serverless env --attribute $NAME --stage $STAGE
#shorthand:
sls env -a $NAME
sls env -a $NAME -s $STAGE
serverless env --decrypt
serverless env --attribute $NAME --decrypt
serverless env --attribute $NAME --stage $STAGE --decrypt
#shorthand:
sls env -a $NAME --decrypt
sls env -a $NAME -s $STAGE -d
Use the following commands to store and encrypt variables in your YAML environment files:
Note that variables are stored to the first file listed in envFiles.
serverless env --attribute $NAME --value $PLAINTEXT
serverless env --attribute $NAME --value $PLAINTEXT --stage $STAGE
#shorthand:
sls env -a $NAME -v $PLAINTEXT
sls env --a $NAME -v $PLAINTEXT --s $STAGE
serverless env --attribute $NAME --value $PLAINTEXT --encrypt
serverless env --attribute $NAME --value $PLAINTEXT --stage $STAGE --encrypt
#shorthand:
sls env -a $NAME -v $PLAINTEXT -e
sls env -a $NAME -v $PLAINTEXT -s $STAGE -e