Google Firebase is used for authentication in VXG Web Client and you can switch to your own Firebase authentication using the following steps:
1. Create a new project in the Firebase console
Go to https://console.firebase.google.com/, click on "Add project"
...
Enter app nickname and click “Register app”
...
2. Create the config.js file
Go to https://console.firebase.google.com/, then go to “Project settings” > “General”, copy firebase config, and store it as file /api/conf.d/config.js
...
Code Block |
---|
const firebaseConfig = { apiKey: "AIzaSyA7qxoxlh85yV-NotUMzBnVtm4OruMVq6Y", authDomain: "testfb-15070.firebaseapp.com", projectId: "testfb-15070", storageBucket: "testfb-15070.appspot.com", messagingSenderId: "764840511", appId: "1:764840511:web:feb0fe8d93c4205bd7068a" }; window.no_check_mail_auth = window.no_check_mail_auth || false; window.no_check_local_addresses = window.no_check_local_addresses || false; window.ipworld_api_key = '8c835497858d45029599768e028939ce'; |
3. Create the firebase.php file
Go to https://console.firebase.google.com/, then “Service accounts” and click “Generate new private key”
...
Edit file /api/conf.d/firebase.php - add 4 characters “<?php” to the beginning of the file and save it
4. Enable Firebase sign-in
Go to https://console.firebase.google.com/, then “Project” > “Authentication” > “Sign-in method” > “Sign-in providers”. Enable email/password provider.
...