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

Google API authentication #9

Closed
hhumphrey84 opened this issue Nov 3, 2015 · 4 comments
Closed

Google API authentication #9

hhumphrey84 opened this issue Nov 3, 2015 · 4 comments

Comments

@hhumphrey84
Copy link

I'm trying to play around with this tool but I'm stumbling at the first hurdle as I don't seem to be able to authenticate with the google API. I've followed all the instructions and it seems to produce the right output which is a clients secrets file:

{
    "installed":{
        "client_id":"xxxx",
        "auth_uri":"https://accounts.google.com/o/oauth2/auth",
        "token_uri":"https://accounts.google.com/o/oauth2/token",
        "auth_provider_x509_cert_url":"https://www.googleapis.com/oauth2/v1/certs",
        "client_secret":"xxxx",
        "redirect_uris":["urn:ietf:wg:oauth:2.0:oob","http://localhost:4567"]
    }
}

I launch Middleman and I get immediately redirected to google where I authenticate with the same account that I used to set up the above. Authenticate but then get redirected back to localhost:9292....I'm not sure why that url? The .google_drive_oauth2.json is never created and the whole thing fails.

Any idea what the issues might be?

Thanks,
Helen

@ryanmark
Copy link
Contributor

ryanmark commented Nov 9, 2015

Hey Helen - did you get this figured out?

@hhumphrey84
Copy link
Author

Yes apologies, I was meant to add that bit of information. After a big of searching around it seems there is an issue with OSX's ruby library at this time (2.2.1):

googleapis/google-api-ruby-client#253

And by adding this:

ENV['SSL_CERT_FILE'] = Gem.loaded_specs['google-api-client'].full_gem_path+'/lib/cacerts.pem'

At the top of my config file, the problem is solved for now...I'm keeping an eye on this and hopefully it can be removed in the future.

@trevrosen
Copy link

I get why RVM/rbenv don't ship one of these, but it seems weird that Apple doesn't just link to the same cacert file that Safari already has, though I suppose it could just be compiled into the bin. FYI I added some commentary to the voxmedia/workstation step that installs one of these files from the Curl maintainers, explaining why it's necessary.

@Nibin96
Copy link

Nibin96 commented Jun 20, 2016

@hhumphrey84 👍 thanx it works for me , i'm using ruby 2.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants