Azure / Azure/custom-script-extension-linux
Getting HTTP 403 when attempting to download fileUris with user-assigned managed identity
- Dominant language
- Go
- Stars
- 113
- Forks
- 46
- Avg merge
- 6d 3h
- Merged PRs (30d)
- 3
Description
Using v2.1.3 of this extension with a user-assigned managed identity, it fails when attempting to download the files defined in `fileUris` with the following errors:
```
time=2020-03-23T23:22:23Z version=v2.1.3/git@4cd2b9f-clean operation=enable seq=6 file=0 event="download start"
time=2020-03-23T23:22:23Z version=v2.1.3/git@4cd2b9f-clean operation=enable seq=6 file=0 retry=0 error="unexpected status code: actual=404 expected=200"
time=2020-03-23T23:22:23Z version=v2.1.3/git@4cd2b9f-clean operation=enable seq=6 file=0 retry=0 info="downloader download.urlDownload returned 404, skipping retries"
time=2020-03-23T23:22:23Z version=v2.1.3/git@4cd2b9f-clean operation=enable seq=6 file=0 retry=0 error="unexpected status code: actual=403 expected=200"
time=2020-03-23T23:22:23Z version=v2.1.3/git@4cd2b9f-clean operation=enable seq=6 file=0 retry=0 info="downloader *download.blobWithMsiToken returned 403, skipping retries"
time=2020-03-23T23:22:23Z version=v2.1.3/git@4cd2b9f-clean operation=enable seq=6 file=0 event="download failed" error="failed to download file: unexpected status code: actual=403 expected=200"
time=2020-03-23T23:22:23Z version=v2.1.3/git@4cd2b9f-clean operation=enable seq=6 event="failed to handle" error="processing file downloads failed: failed to download file[0]: failed to download file: unexpected status code: actual=403 expected=200"
```
I've double checked that the user-assigned identity has the proper role assignments for both the VM and the Storage Account (Contributor role in both cases).
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.