#!/usr/bin/env sh
# Push tagger binaries to AWS.
# This is run by circle-ci when building due to a tag.
#
# Prerequisites:
# - binaries must be statically linked by running build/build-static-binaries.sh
# - circleci must have AWS credentials configured
# - AWS credentials must have S3 write permissions on the bucket
# - the aws cli must be installed on the machine
# - the region must be configured
#
# Ask marc@cockroachlabs.com for the aws credentials file to use, then follow the
# steps in circle.yml to configure aws and generate the binaries.

set -eux

if [ -z "${CIRCLE_TAG}" ]; then
  echo "$0 called without a CIRCLE_TAG environment variable"
  exit 1
fi

cd "$(dirname "${0}")"

# Tar up and push linux/osx binaries. One tagged, one called "latest".
./push-release-tarball.sh cockroach cockroach-${CIRCLE_TAG}.linux-amd64
./push-release-tarball.sh cockroach cockroach-latest.linux-amd64
# The OSX binary name is generated by build-osx.sh. One tagged, one called "latest".
./push-release-tarball.sh cockroach-darwin-10.9-amd64 cockroach-${CIRCLE_TAG}.darwin-10.9-amd64
./push-release-tarball.sh cockroach-darwin-10.9-amd64 cockroach.latest.darwin-10.9-amd64

#!/usr/bin/env sh
# Push tagger binaries to AWS.
# This is run by circle-ci when building due to a tag.
#
# Prerequisites:
# - binaries must be statically linked by running build/build-static-binaries.sh
# - circleci must have AWS credentials configured
# - AWS credentials must have S3 write permissions on the bucket
# - the aws cli must be installed on the machine
# - the region must be configured
#
# Ask marc@cockroachlabs.com for the aws credentials file to use, then follow the
# steps in circle.yml to configure aws and generate the binaries.

set -eux

if [ -z "${CIRCLE_TAG}" ]; then
  echo "$0 called without a CIRCLE_TAG environment variable"
  exit 1
fi

cd "$(dirname "${0}")"

# Tar up and push linux/osx binaries. One tagged, one called "latest".
./push-release-tarball.sh cockroach cockroach-${CIRCLE_TAG}.linux-amd64
./push-release-tarball.sh cockroach cockroach-latest.linux-amd64
# The OSX binary name is generated by build-osx.sh. One tagged, one called "latest".
./push-release-tarball.sh cockroach-darwin-10.9-amd64 cockroach-${CIRCLE_TAG}.darwin-10.9-amd64
./push-release-tarball.sh cockroach-darwin-10.9-amd64 cockroach-latest.darwin-10.9-amd64

Fix typo on master as well
Fix typo on master as well
