Teach you step by step how to integrate google sign-in
1. Create a new project on Google Cloud
2. Go to APIs & Services then Credentials
3. Click [Configure Consent Screen]
4. Do not upload App logo to avoid review. (recommend this)
5. Add userinfo.email & userinfo.profile to scope
6. Add yourself as a test user. Then submit
7. Go to Credentials and click [+ Create Credentials] then [Oauth Client ID]
8. Choose [Web Application]
9. Add 4 url to input
Add http://localhost and https://your-domain to Authorized JavaScript origins. Add http://localhost/api/auth/callback/google and https://your-domain/api/auth/callback/google to Authorized redirect URIs
Click [Create]
10. Copy paste the Client ID in GOOGLE_ID and Client Secret in GOOGLE_SECRET to .env.local(GOOGLE_CLIENT_ID、GOOGLE_SECRET_ID)
11. Go to [Oauth Consent Screen] and click [Publish App] to publish this to production
a. If you upload App logo in the fourth step, you need Click [Prepare for verification] and fill the missing information.
b. Google will email you and you will have to reply to start the process. You'll need to have your domain verified with Google Search Console. You can go ahead and do that now.
c. You can already login with Google on localhost. On production, it will work too but show a warning until you're verified (takes a few days).
d. If you don't upload App logo in the fourth step, your app will be ready to use immediately! (recommend this!)