mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-22 01:12:31 +00:00
Makefile cleanup and travis-ci s3 deploy (#6329)
- pulls more of the travis-ci s3 deploy into the repo so we can potentially migrate to another CI system - fixed the sizes output and added verbose compiler version to cmake (#6322) - fixed filenames for firmware uploaded to s3 (was broken by the changes yesterday) - fixed some broken git version display in cmake - Makefile organization - simplified .travis.yml - added a print to know which config the nuttx patch was being applied to - docker_run.sh now respects PX4_DOCKER_REPO for setting the docker image, but defaults to the good production nuttx image
This commit is contained in:
21
Tools/s3put.sh
Executable file
21
Tools/s3put.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
|
||||
filename=${1}
|
||||
|
||||
# Requires these ENV variables
|
||||
# AWS_ACCESS_KEY_ID
|
||||
# AWS_SECRET_ACCESS_KEY
|
||||
# AWS_S3_BUCKET
|
||||
|
||||
[ -z "$AWS_ACCESS_KEY_ID" ] && { echo "ERROR: Need to set AWS_ACCESS_KEY_ID"; exit 1; }
|
||||
[ -z "$AWS_SECRET_ACCESS_KEY" ] && { echo "ERROR: Need to set AWS_SECRET_ACCESS_KEY"; exit 1; }
|
||||
[ -z "$AWS_S3_BUCKET" ] && { echo "ERROR: Need to set AWS_S3_BUCKET"; exit 1; }
|
||||
|
||||
if [ -f ${filename} ]; then
|
||||
base_file_name=`basename $filename`
|
||||
short_file_name=${base_file_name#nuttx-}
|
||||
s3cmd --access_key=${AWS_ACCESS_KEY_ID} --secret_key=${AWS_SECRET_ACCESS_KEY} put ${filename} s3://${AWS_S3_BUCKET}/${short_file_name}
|
||||
else
|
||||
echo "ERROR: ${file} doesn't exist"
|
||||
exit 1
|
||||
fi
|
||||
Reference in New Issue
Block a user