Skip to content

Instantly share code, notes, and snippets.

@ptqa
Created December 12, 2016 14:29
Show Gist options
  • Save ptqa/a058cf6869db60527ed2ebc50170317c to your computer and use it in GitHub Desktop.
Save ptqa/a058cf6869db60527ed2ebc50170317c to your computer and use it in GitHub Desktop.
#!/bin/bash
if [ $# -eq 0 ]; then
BRANCH="master"
else
BRANCH=$1
fi
filename="$(basename $(pwd))_$BRANCH.tar.gz";
berks package "/tmp/$filename";
aws --region eu-west-1 s3 cp "/tmp/$filename" s3://chef-bundles;
echo "uploaded: https://s3-eu-west-1.amazonaws.com/chef-bundles/$filename"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment