Development Authentication
When developing your Allinix application locally, you can use a simplified authentication system. This streamlines testing and debugging but should never be used in production environments.
⚠️ Warning: The development authentication mode is not secure and should only be used for local testing.
To configure authentication:
Set
NODE_ENV="development"in your.envfile to enable development modeSet
NEXTAUTH_SECRETto any value (e.g., "development-secret") for local testing
OAuth Provider Setup
Google Authentication Setup
Navigate to the Google Cloud Console
Create a new project
Go to "Credentials" → "Create Credentials" → "OAuth client ID"
Set up the OAuth consent screen
Copy the generated client ID and secret
Add to
.env:
GOOGLE_CLIENT_ID="your_client_id"
GOOGLE_CLIENT_SECRET="your_client_secret"For detailed setup instructions, visit Google's OAuth 2.0 setup guide.
GitHub Authentication Setup
Open GitHub Settings → Developer Settings
Select "OAuth Apps" → "New OAuth App"
Configure your application settings
Copy the client ID and generated secret
Add to
.env:
For detailed setup instructions, visit GitHub's OAuth Apps documentation.
Discord Authentication Setup
Create a new application
Configure OAuth2 settings and add redirect URIs
Copy the application ID and secret
Add to
.env:
For detailed setup instructions, visit the Discord OAuth2 documentation.
Production Configuration
When deploying to production, follow these essential steps:
ℹ️ Note: Ensure all credentials and secrets are properly secured and never committed to version control.
Generate a strong, random value for
NEXTAUTH_SECRETSet
NEXTAUTH_URLto your production domain (cannot be localhost)Ensure all OAuth provider credentials are properly configured
Set
NODE_ENV="production"
Example production .env configuration:
⚠️ Warning: Never commit your
.envfile to version control. Use environment variables in your deployment platform to manage sensitive credentials.
Last updated


