# Licensed under the terms of the GNU GPL v2
# Copyright 2007 Victor Lowther <victor.lowther@gmail.com>
+CURL=/home/mwolson_admin/bin/curl
HMAC=$(dirname $0)/s3-hmac
# print a message and bail
}
check_deps() {
- check_dep openssl date cat grep curl
+ check_dep openssl date cat grep
check_hmac
check_s3
}
headers[${#headers[@]}]="Authorization: AWS ${S3_ACCESS_KEY_ID}:${sig}"
headers[${#headers[@]}]="Date: ${date}"
[[ ${md5} ]] && headers[${#headers[@]}]="Content-MD5: ${md5}"
- curl ${arg} "${inout}" ${stdopts} -K <(curl_headers "${headers[@]}") \
+ $CURL ${arg} "${inout}" ${stdopts} -K <(curl_headers "${headers[@]}") \
"http://s3.amazonaws.com${bucket}${remote}"
return $?
}
# $1 = remote bucket to put it into
# $2 = remote name to put
# $3 = file to put. This must be present if $2 is.
- $ $4 = bandwidth limit.
+ # $4 = bandwidth limit.
s3_curl PUT "${1}" "${2}" "${3:-${2}}" "${4}"
return $?
}
# $2 = remote file to get
# $3 = local file to get into. Will be overwritten if it exists.
# If this contains a path, that path must exist before calling this.
- $ $4 = bandwidth limit.
+ # $4 = bandwidth limit.
s3_curl GET "${1}" "${2}" "${3:-${2}}" "${4}"
return $?
}