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

Port to oauth2, fix #606 #900

Merged
merged 7 commits into from
Feb 12, 2015
Merged

Port to oauth2, fix #606 #900

merged 7 commits into from
Feb 12, 2015

Conversation

sparkprime
Copy link
Contributor

Terraform equivalent of part 1 of hashicorp/packer#1679

One question: If the account_file is not given it should attempt to get tokens from the metadata server. However I cannot figure out how to avoid this prompt:

provider.google.account_file
  Enter a value: 

At the moment you have to explicitly specify the empty string in the config to avoid the prompt. In my opinion this is fine but is it what you want?

phinze added a commit that referenced this pull request Jan 30, 2015
Currently when running `make updatedeps` from a branch, the dependency
list from master ends up getting used. We tried to work around this in
35490f7, and got part way there, but
here's what was happening:

 - record the current SHA
 - run `go get -f -u -v ./...` which ends up checking out master
 - master is checked out early in the `go get` process, which means all
   subsequent dependencies are resolved from master
 - re-checkout the recorded SHA
 - run tests

This works in most cases, except when the branch being tested actually
changes the list of dependencies in some way.

Here we move away from letting `go get -v` walk through everything in
`./...`, instead building our own list of dependencies with the help of
`deplist`. We can then filter terraform packages out from the list, so
they don't get touched, and safely update the rest.

This should solve problems like those observed in #899 and #900.

__Note__: had to add a feature to deplist to make this work properly;
see phinze/deplist@016ef97
Working on getting it accepted upstream.
@phinze
Copy link
Contributor

phinze commented Jan 30, 2015

Alright now that #901 has landed, I think if you rebase on master then all should be well!

@sparkprime
Copy link
Contributor Author

Can one of you comment on my original question about the prompt? thanks

@phinze
Copy link
Contributor

phinze commented Jan 30, 2015

At the moment you have to explicitly specify the empty string in the config to avoid the prompt. In my opinion this is fine but is it what you want?

Seems fine to me too, and you mention it in the docs. 👍

"github.com/rasa/oauth2-fork-b3f9a68"

// oauth2 "github.com/rasa/oauth2-fork-b3f9a68/google"
"github.com/rasa/oauth2-fork-b3f9a68/google"
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we verify that this fork is still necessary? I found hashicorp/packer@10dee1b but I can't seem to find any commentary on what exactly broke and what needs to be fixed upstream.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I am not sure. I tried github.com/golang/oauth2/google and couldn't work out how to make the build systems pull in the dependency. When I saw packer using the other one I just copied that and it worked. I'd like to know the full story as well.

@sparkprime
Copy link
Contributor Author

@phinze re: comment earlier about whether the fork is still necessary, this is upstream (copied from the Packer PR), but it won't build (updatedeps) and I'm not sure why. Any ideas? thanks

@sparkprime
Copy link
Contributor Author

@lamielle Oops I forgot to tag you. Better late than never!

@lamielle
Copy link
Contributor

Thanks @sparkprime! Glad to see this PR!

@sparkprime
Copy link
Contributor Author

@phinze Thanks for the pointers, seems to be OK now. The same modifications could (should?) be made to Packer.

@phinze
Copy link
Contributor

phinze commented Feb 12, 2015

Nice! Much cleaner. 🚿

phinze added a commit that referenced this pull request Feb 12, 2015
@phinze phinze merged commit 625f440 into hashicorp:master Feb 12, 2015
yahyapo pushed a commit to yahyapo/terraform that referenced this pull request Mar 13, 2015
Currently when running `make updatedeps` from a branch, the dependency
list from master ends up getting used. We tried to work around this in
35490f7, and got part way there, but
here's what was happening:

 - record the current SHA
 - run `go get -f -u -v ./...` which ends up checking out master
 - master is checked out early in the `go get` process, which means all
   subsequent dependencies are resolved from master
 - re-checkout the recorded SHA
 - run tests

This works in most cases, except when the branch being tested actually
changes the list of dependencies in some way.

Here we move away from letting `go get -v` walk through everything in
`./...`, instead building our own list of dependencies with the help of
`deplist`. We can then filter terraform packages out from the list, so
they don't get touched, and safely update the rest.

This should solve problems like those observed in hashicorp#899 and hashicorp#900.

__Note__: had to add a feature to deplist to make this work properly;
see phinze/deplist@016ef97
Working on getting it accepted upstream.
@ghost
Copy link

ghost commented May 4, 2020

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators May 4, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants