mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
try to fix output file
This commit is contained in:
@@ -2,19 +2,15 @@
|
|||||||
# fail script immediately on any errors in external commands and print the lines
|
# fail script immediately on any errors in external commands and print the lines
|
||||||
set -ev
|
set -ev
|
||||||
|
|
||||||
outputFile=$HOME/rm-automation
|
outputFile=$HOME/rm-automation/alfresco-content-services-installer-5.2.7.4-linux-x64.bin
|
||||||
amzFile="release/enterprise/5.2/5.2.7/5.2.7.4/alfresco-content-services-installer-5.2.7.4-linux-x64.bin"
|
amzFile="/eu.dl.alfresco.com/release/enterprise/5.2/5.2.7/5.2.7.4/alfresco-content-services-installer-5.2.7.4-linux-x64.bin"
|
||||||
region="eu-west-1"
|
host="s3-eu-west-1.amazonaws.com"
|
||||||
bucket="eu.dl.alfresco.com"
|
|
||||||
resource="/${bucket}/${amzFile}"
|
|
||||||
contentType="binary/octet-stream"
|
contentType="binary/octet-stream"
|
||||||
dateValue=`TZ=GMT date -R`
|
dateValue=`TZ=GMT date -R`
|
||||||
stringToSign="GET\n\n${contentType}\n${dateValue}\n${resource}"
|
stringToSign="GET\n\n${contentType}\n${dateValue}\n${amzFile}"
|
||||||
s3Key=$RELEASE_AWS_ACCESS_KEY
|
signature=`echo -en ${stringToSign} | openssl sha1 -hmac $RELEASE_AWS_SECRET_KEY -binary | base64`
|
||||||
s3Secret=$RELEASE_AWS_SECRET_KEY
|
curl -H "Host: ${host}" \
|
||||||
signature=`echo -en ${stringToSign} | openssl sha1 -hmac ${s3Secret} -binary | base64`
|
|
||||||
curl -H "Host: s3-${region}.amazonaws.com" \
|
|
||||||
-H "Date: ${dateValue}" \
|
-H "Date: ${dateValue}" \
|
||||||
-H "Content-Type: ${contentType}" \
|
-H "Content-Type: ${contentType}" \
|
||||||
-H "Authorization: AWS ${s3Key}:${signature}" \
|
-H "Authorization: AWS $RELEASE_AWS_ACCESS_KEY:${signature}" \
|
||||||
https://s3-${region}.amazonaws.com/${bucket}/${amzFile} -o ${outputFile}
|
https://${host}${amzFile} -o ${outputFile}
|
||||||
|
Reference in New Issue
Block a user