Skip to content

overwrite flag added to az storage blob upload-batch#10726

Merged
jdolitsky merged 3 commits into
helm:mainfrom
sourikghosh:fix/10724-sh
Mar 8, 2022
Merged

overwrite flag added to az storage blob upload-batch#10726
jdolitsky merged 3 commits into
helm:mainfrom
sourikghosh:fix/10724-sh

Conversation

@sourikghosh

Copy link
Copy Markdown
Contributor

Signed-off-by: Sourik Ghosh [email protected]

What this PR does / why we need it:
adds a overwrite flag to az storage blob upload-batch to replace canary.
closes #10724

Special notes for your reviewer:

If applicable:

  • this PR contains documentation
  • this PR contains unit tests
  • this PR has been tested for backwards compatibility

@pull-request-size pull-request-size Bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Mar 5, 2022
@yxxhero

yxxhero commented Mar 5, 2022

Copy link
Copy Markdown
Member

/lgtm
Thanks your PR.

@yxxhero
yxxhero requested a review from jdolitsky March 5, 2022 06:09
@sourikghosh

Copy link
Copy Markdown
Contributor Author

@jdolitsky can you have a look at this

@jdolitsky jdolitsky left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was thinking about this. The new behavior actually protects from supply chain attacks.

Could you modify this to only add --overwrite if [[ "${VERSION}" == "canary" ]] ?

Comment thread .circleci/deploy.sh
Comment on lines +49 to +53
if [[ "${VERSION}" == "canary" ]]; then
az storage blob upload-batch -s _dist/ -d "$AZURE_STORAGE_CONTAINER_NAME" --pattern 'helm-*' --connection-string "$AZURE_STORAGE_CONNECTION_STRING" --overwrite
else
az storage blob upload-batch -s _dist/ -d "$AZURE_STORAGE_CONTAINER_NAME" --pattern 'helm-*' --connection-string "$AZURE_STORAGE_CONNECTION_STRING"
if No newline at end of file

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

last thing, can we format this?

if [[ "${VERSION}" == "canary" ]]; then
  az storage blob upload-batch -s _dist/ -d "$AZURE_STORAGE_CONTAINER_NAME" --pattern 'helm-*' --connection-string "$AZURE_STORAGE_CONNECTION_STRING" --overwrite
else
  az storage blob upload-batch -s _dist/ -d "$AZURE_STORAGE_CONTAINER_NAME" --pattern 'helm-*' --connection-string "$AZURE_STORAGE_CONNECTION_STRING"
if

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ohhh snap,,, yeah yeah

Signed-off-by: Sourik Ghosh <[email protected]>
@sourikghosh
sourikghosh requested a review from jdolitsky March 8, 2022 18:57
@jdolitsky

Copy link
Copy Markdown
Contributor

thanks @sourikghosh !

@jdolitsky
jdolitsky merged commit d61b9be into helm:main Mar 8, 2022
@jdolitsky jdolitsky added this to the 3.8.1 milestone Mar 8, 2022
@mattfarina mattfarina added needs-pick Indicates that a PR needs to be cherry-picked into the next release candidate. picked Indicates that a PR has been cherry-picked into the next release candidate. labels Mar 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-pick Indicates that a PR needs to be cherry-picked into the next release candidate. picked Indicates that a PR has been cherry-picked into the next release candidate. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

New azure-cli requires --overwrite to replace canary

4 participants