How to generate ".env" when Deploying with Bitbucket AWS CodeDeploy add-on?
I see bitbucket-pipelines.yml
can generate .env from bitbucket environment variables, but, how tie it up with Bitbucket AWS CodeDeploy add-on?
appspec.yml
- can trigger script on deployment but how can I make it get .env from bitbucket environment variables?
BitBucket
should not create.env
, this service should know nothing about production.env
. Instead the production.env
should sit on secureAWS S3 bucket
where onlyAWS CodeDeploy
scripts can take it and put on the instance.it would be copied like this