remove envvar for s3 path from config file and error check s3 cp
This commit is contained in:
parent
33344ece37
commit
2f10fc4a69
|
@ -21,7 +21,6 @@ references:
|
|||
GIT_AUTHOR_NAME: circleci-consul
|
||||
GIT_COMMITTER_NAME: circleci-consul
|
||||
S3_ARTIFACT_BUCKET: consul-dev-artifacts
|
||||
S3_ARTIFACT_PATH: consul-oss
|
||||
|
||||
jobs:
|
||||
# build all distros
|
||||
|
@ -98,9 +97,14 @@ jobs:
|
|||
- run:
|
||||
name: Upload to s3
|
||||
command: |
|
||||
aws s3 cp \
|
||||
--metadata "CIRCLECI=${CIRCLECI},CIRCLE_BUILD_URL=${CIRCLE_BUILD_URL},CIRCLE_BRANCH=${CIRCLE_BRANCH}" \
|
||||
"consul.tar.gz" "s3://${S3_ARTIFACT_BUCKET}/${S3_ARTIFACT_PATH}/${CIRCLE_SHA1}.tar.gz"
|
||||
if [ -n "${S3_ARTIFACT_PATH}" ]; then
|
||||
aws s3 cp \
|
||||
--metadata "CIRCLECI=${CIRCLECI},CIRCLE_BUILD_URL=${CIRCLE_BUILD_URL},CIRCLE_BRANCH=${CIRCLE_BRANCH}" \
|
||||
"consul.tar.gz" "s3://${S3_ARTIFACT_BUCKET}/${S3_ARTIFACT_PATH}/${CIRCLE_SHA1}.tar.gz"
|
||||
else
|
||||
echo "CircleCI - S3_ARTIFACT_PATH was not set"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Nomad 0.8 builds on go0.10
|
||||
# Run integration tests on nomad/v0.8.7
|
||||
|
|
Loading…
Reference in New Issue