Skip to content

Authentication as as Administrator on Homestead

Mike Hingley edited this page Oct 12, 2018 · 1 revision

The Developing on Homestead document details how to set up a homestead instance - but what if you want to use the administration sections of the site on homestead?

Pre-requisites

The administration section is best accessed through google - Here's how it works.

user requests cchits.net/google, and are asked to select an account to log on with. They are redirected back to https://cchits.net/oauth2callback.

Challenge 1 - Setting up a google project.

To get authentication working you'll need to create a Google project - visit https://console.cloud.google.com and create a project. Once you've created a project add some credentials by visiting this link and selecting your new project.

This screenshot shows my project configuration.

Challenge 2 - Setting up a suitable set of return / serve addresses

Google oAuth authentication requires that return addresses are valid tld based addresses - so my development environment of cchits.local won't cut it here. Instead I've modified my homestead.yaml file to include a cchits.net address.

Challenge 3 - Setting up a suitable address