Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

r/storage_queue: switching to use SharedKeyLite for auth #4122

Merged
merged 8 commits into from Aug 22, 2019

Conversation

tombuildsstuff
Copy link
Member

@tombuildsstuff tombuildsstuff commented Aug 20, 2019

This PR fixes a couple of bugs around Storage Queues:

  1. Switches to using SharedKey for authentication rather than AzureAD - since apparently the Azure Storage API's require an additional permission (on top of Owner/Contributor) to access the Storage API's (and which can't be configured at the root if a DataBricks cluster is provisioned)
  2. The Environment wasn't being set correctly for the Storage Queues API, such that this defaulted to Azure Public

Unfortunately I'm unable to reproduce #3939, but I believe this should fix it.

Fixes #3939
Fixes #3925

Copy link
Collaborator

@katbyte katbyte left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@tombuildsstuff tombuildsstuff self-assigned this Aug 20, 2019
@ghost ghost added size/L and removed size/M labels Aug 21, 2019
@tombuildsstuff tombuildsstuff changed the title r/storage_queue: switching to use SharedKey for auth [WIP] r/storage_queue: switching to use SharedKey for auth Aug 21, 2019
@tombuildsstuff
Copy link
Member Author

Requires vendoring tombuildsstuff/giovanni#4

```
=== RUN   TestComputeSharedKey
--- PASS: TestComputeSharedKey (0.00s)
    authorizer_shared_key_lite_test.go:87: [DEBUG] Test "No Path"
    authorizer_shared_key_lite_test.go:87: [DEBUG] Test "With Path"
PASS
```
@ghost ghost added dependencies size/XXL and removed size/L labels Aug 21, 2019
@tombuildsstuff tombuildsstuff changed the title [WIP] r/storage_queue: switching to use SharedKey for auth r/storage_queue: switching to use SharedKey for auth Aug 21, 2019
```
=== RUN   TestValidateStorageShareDirectoryName
--- PASS: TestValidateStorageShareDirectoryName (0.00s)
    storage_test.go:49: [DEBUG] Test Input ""
    storage_test.go:49: [DEBUG] Test Input "abc123"
    storage_test.go:49: [DEBUG] Test Input "123abc"
    storage_test.go:49: [DEBUG] Test Input "123-abc"
    storage_test.go:49: [DEBUG] Test Input "-123-abc"
    storage_test.go:49: [DEBUG] Test Input "123-abc-"
    storage_test.go:49: [DEBUG] Test Input "123--abc"
    storage_test.go:49: [DEBUG] Test Input "hello/world"
    storage_test.go:49: [DEBUG] Test Input "hello/"
PASS
```
@tombuildsstuff
Copy link
Member Author

Tests look good 👍

@tombuildsstuff tombuildsstuff merged commit c77aeb0 into master Aug 22, 2019
@tombuildsstuff tombuildsstuff deleted the f/storage-queue branch August 22, 2019 07:24
tombuildsstuff added a commit that referenced this pull request Aug 22, 2019
@ghost
Copy link

ghost commented Aug 22, 2019

This has been released in version 1.33.0 of the provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. As an example:

provider "azurerm" {
    version = "~> 1.33.0"
}
# ... other configuration ...

@invidian
Copy link
Contributor

invidian commented Sep 2, 2019

This PR is actually misleading, since it switches storage_queue to use SharedKeyLite, not SharedKey.

@tombuildsstuff
Copy link
Member Author

@invidian we're aware and looking into this, in this case it's used as an abbreviation since it appeared that SharedKey authentication was superflurious

@tombuildsstuff tombuildsstuff changed the title r/storage_queue: switching to use SharedKey for auth r/storage_queue: switching to use SharedKeyLite for auth Sep 2, 2019
@ghost
Copy link

ghost commented Sep 21, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks!

@hashicorp hashicorp locked and limited conversation to collaborators Sep 21, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
3 participants