Skip to content

Commit

Permalink
added compressions
Browse files Browse the repository at this point in the history
  • Loading branch information
ashishsingh101 committed Mar 9, 2024
1 parent 9c2a987 commit 41432bf
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
5 changes: 4 additions & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,10 @@ pipeline {

echo "starting s3 push .........................."
def s3Path = "s3://beckn-frontend-assets/${file}"
sh ("aws s3 cp ./${file} ${s3Path}")

sh ("./push.sh ${file} ${s3Path}")
// sh ("aws s3 cp ./${file} ${s3Path}")

uploadedFiles += "\n${file}"
}
}
Expand Down
Binary file modified beckn/passculture/user/images/dummy3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 5 additions & 4 deletions push.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,18 +64,19 @@ push_asset() {

printf "Pushing $local_path to $s3_path ...\n\n"

npm run s3:uploadFile $local_path $s3_path --prefix node_modules/release-scripts -- --public --titan # TODO :: create promise for api call to S3
aws s3 cp $local_path $s3_path
# npm run s3:uploadFile $local_path $s3_path --prefix node_modules/release-scripts -- --public --titan # TODO :: create promise for api call to S3
}

asset=""
bucket=jp-remote-assets # TODO : set PROD bucket
bucket="beckn-frontend-assets" # TODO : set PROD bucket
force_push=false

if [ $(echo $@ | sed "s/--[a-zA-Z]*-*[a-zA-Z]*//g" | tr -d '[:space:]' | wc -c) -ne 0 ]
then asset=$(echo $@ | sed "s/--[a-zA-Z]*-*[a-zA-Z]*//g" | tr -d '[:space:]'); fi

if [[ "$@" =~ --sandbox ]]
then bucket="beta-hyper-sdk-assets"; fi # TODO :: set sandbox bucket (optional)
then bucket="beckn-frontend-assets"; fi # TODO :: set sandbox bucket (optional)

echo -------------- s3 push starting -------------------

Expand Down Expand Up @@ -123,5 +124,5 @@ then

pathToPush="s3://$bucket/$asset"
push_asset $local_path $pathToPush
invalidate_asset $pathToPush
# invalidate_asset $pathToPush
fi

0 comments on commit 41432bf

Please sign in to comment.