I've been trying the aws-s3-deploy pipeline (https://bitbucket.org/atlassian/aws-s3-deploy), with little success.
My goal is to exclude the .git folder from deployment. According to the pipelin documentation, I set the var
EXTRA_ARGS: "--exclude '.git/*'"
The pipeline runs correctly, but the .git folder is always uploaded to S3. If I use double quotes, it is also uploaded. If I remove the quotes, an error happens (because the shell tries to expand).
Whenever I don't use quotes, and I don't use wildcards, for example
EXTRA_ARGS: "--exclude README.md"
everything works as expected and the file is excluded. So the problem seems to be whenever I want to use wildcards.
Any ideas on how to exclude the .git folder from deployment?
No, exchanging single for double quotes (or the opposite) does not work. This is the log from the pipeline console:
( ... )
Status: Downloaded newer image for bitbucketpipelines/aws-s3-deploy:0.2.2
INFO: Starting deployment to S3...
aws s3 sync . s3://<my-bucket-here>/ --cache-control=max-age=3600 --delete --exclude README.md --exclude ".git/*"
Completed 23 Bytes/~2.2 MiB (122 Bytes/s) with ~88 file(s) remaining (calculating...)
upload: .git/HEAD to s3://<my-bucket-here>/.git/HEAD
(... etc ...)
Hi, Bitbucket community! Are you a DevOps practitioner (or know one in your network)? Do you have DevOps tips, tricks, or learnings you'd like to share with the community? If so, we'd love to hea...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events