Admin Role Overview
Admins are identified by their email address matching theNETBIRD_ADMIN_EMAIL environment variable. Admin capabilities include:
- Creating resources without approval
- Approving or denying user requests
- Editing and deleting any resource (not just owned resources)
- Viewing complete activity logs
- Managing all users’ resources
- Receiving approval request notifications
Configuring Admin Access
Setting the Admin Email
Admin access is configured in your.env file:
Choose Admin Email
Select the email address of the person who will be the primary admin.
This must match the email address used for Google OAuth authentication.
Clear Cache and Restart
Apply the configuration change:If using a process manager, restart your application.
Multiple Admins
Currently, the system supports a single admin email. For multiple admins, you have these options:Shared Email Alias (Recommended)
Shared Email Alias (Recommended)
Code Modification (Advanced)
Code Modification (Advanced)
Modify the admin check logic to support multiple admins:
- Update
.envwith comma-separated emails:
- Modify admin check logic in your application code to parse and check against the array.
Role-Based System (Custom Development)
Role-Based System (Custom Development)
Implement a proper role-based access control system:
- Add
is_adminboolean to users table - Create admin management interface
- Update authorization logic throughout the application
Approval Workflow
When users submit resource requests, admins receive notifications and must approve or deny them.Email Approval Process
Receive Notification Email
When a user submits a request, you receive an email with:
- Resource name and address
- Description and purpose
- Requester’s name and email
- Request date
- Two action links: Approve and Deny
New Resource for Approval: [Resource Name]Review Request Details
Evaluate the request based on:Technical Validity
- Is the address format correct?
- Is it a customer network or legitimate resource?
- Does the CIDR range make sense?
- Is the request from an authorized user?
- Is the scope appropriate (not overly broad)?
- Does it follow security policies?
- Is there a valid business need?
- Is this related to an active project?
- Has the customer approved this access?
Take Action
Click one of the action links in the email:Approve
- Resource is created in NetBird immediately
- User receives approval notification
- Resource appears in user’s dashboard
- Activity is logged
- Request is marked as denied
- User receives rejection notification
- Request appears in user’s history
- Activity is logged
Approval links are signed URLs valid for 7 days. After expiration, you’ll need to manage requests through the web portal.
Portal Approval Process
You can also manage requests through the web portal:View Pending Requests
Go to the “Pending Requests” section or filter resources by “Pending” status.You’ll see all pending requests from all users.
Review Request
Click on a pending request to view full details:
- Complete resource information
- Requester details
- Submission timestamp
- Request description
Creating Resources as Admin
Admins can create resources directly without going through the approval process:Bulk Resource Creation
For creating many resources at once:Manual Bulk Creation
Manual Bulk Creation
Create multiple resources through the UI in succession:
- Fill out the form
- Submit
- Immediately click “New Resource” again
- Repeat for each resource
Direct NetBird Dashboard
Direct NetBird Dashboard
For very large imports:
- Sign in to NetBird dashboard
- Use NetBird’s bulk import features (if available)
- Resources created in NetBird will be visible but not tracked in Selfservice
API or Script (Advanced)
API or Script (Advanced)
Use Laravel Tinker or a custom script:
Managing All Resources
As an admin, you can manage resources created by any user:Viewing All Resources
- Dashboard View: See all resources from all users
- Filter by User: Find resources by creator
- Filter by Status: View active, disabled, or pending resources
- Search: Search by name or address
Editing Any Resource
Deleting Any Resource
Activity Logs
Admins have access to comprehensive activity logs:What’s Logged
All resource-related actions are logged:- Resource created (admin or user)
- Resource requested (non-admin user)
- Request approved
- Request denied
- Resource updated
- Resource deleted
- Resource enabled/disabled
Log Information
Each log entry includes:- Timestamp: When the action occurred
- Action: What was done
- Resource: Name and address
- User: Who performed the action
- Changes: What changed (for updates)
- NetBird ID: NetBird resource identifier
Viewing Logs
Filter Logs
Use filters to find specific activities:
- By date range
- By user
- By action type
- By resource name
Log Retention
Logs are stored in the application database:- No automatic deletion
- Can be manually cleaned up if needed
- Consider implementing log rotation for long-term deployments
User Management
While there’s no built-in user management interface, admins can manage users through the database:Viewing Users
Users are automatically created when they first sign in via OAuth:User Information
Each user record contains:- Name (from OAuth provider)
- Google ID (OAuth identifier)
- Avatar URL
- Created timestamp
Removing Users
If you need to remove a user:- Remove from OAuth provider: Disable their account in Google Workspace
- Optional: Delete user from database:
Email Configuration
Admins need to ensure email notifications work properly:Testing Email
Verify email configuration:Email Providers
Configure your email provider in.env:
For Gmail, you need to use an App Password, not your regular password.
Security Best Practices
Admin Account Security
Admin Account Security
Protect Admin Credentials
- Use strong, unique password for admin email
- Enable 2FA on admin Google account
- Don’t share admin credentials
- Regularly audit admin access
- Only designate necessary personnel as admins
- Use shared email alias for multiple admins
- Document who has admin access
- Review admin activity regularly
Resource Approval Guidelines
Resource Approval Guidelines
Always Verify
- Confirm requester identity
- Validate business need
- Check with project managers if unsure
- Verify customer authorization
- Reject overly broad ranges (e.g.,
0.0.0.0/0) - Question suspicious addresses
- Verify domains are legitimate
- Check for typos in addresses
- Require detailed descriptions
- Ask for ticket numbers
- Note any special circumstances
- Document approval reasoning
Regular Maintenance
Regular Maintenance
Weekly
- Review pending requests
- Process approvals promptly
- Check for abandoned requests
- Audit all active resources
- Remove unused resources
- Review activity logs
- Verify users still need access
- Full security audit
- Review admin access
- Update documentation
- Test disaster recovery procedures
Incident Response
Incident Response
If You Suspect Compromise
- Immediately disable suspicious resources
- Review recent activity logs
- Check for unauthorized changes
- Rotate NetBird API token
- Force re-authentication of all users
- Contact security team
- Disable OAuth account immediately
- Change
NETBIRD_ADMIN_EMAILin.env - Review all recent admin actions
- Audit all resources for unauthorized changes
- Rotate all credentials
- Notify security team and users
Troubleshooting
Admin Features Not Visible
Problem: Signed in with admin email but don’t see admin features Solutions:- Verify email in
.envmatches exactly: - Clear configuration cache:
- Sign out and sign back in
- Check that email case matches (some systems are case-sensitive)
Approval Emails Not Received
Problem: No email notifications when users submit requests Solutions:- Check spam/junk folder
- Verify
NETBIRD_ADMIN_EMAILis correct - Test email configuration:
- Check Laravel logs:
storage/logs/laravel.log - Verify mail provider settings in
.env
Approval Links Expired
Problem: Clicked approval link but got “expired” or “invalid” error Solutions:- Approval links expire after 7 days
- Sign in to the portal and approve from there
- Request user to resubmit if needed
Can’t Delete Resource
Problem: Error when trying to delete a resource Solutions:- Check NetBird API connectivity
- Verify NetBird API token hasn’t expired
- Check if resource was already deleted in NetBird
- Review application logs for specific errors
Best Practices for Admins
Next Steps
- User Guide - Understand the user perspective
- OAuth Setup - Review authentication configuration
- NetBird Setup - Technical details of NetBird integration