# In RStudio or R console:
library(shiny)
source("lib/FInOpsApp.R")
shinyApp(ui, server)
# Or run launcher
The login page is now the first screen. Try these credentials:
Admin User (Full Access)
- Username:
admin - Password:
admin_password - Expected: See all tabs in navigation bar
FinOps Analyst (Cost/Cloud Focus)
- Username:
analyst - Password:
analyst_password - Expected: Dashboard, Multi-Cloud, Reports tabs only
DevOps Engineer (K8s Focus)
- Username:
devops - Password:
devops_password - Expected: Dashboard, Kubernetes tabs only
Viewer (Read-Only)
- Username:
viewer - Password:
viewer_password - Expected: Dashboard tab only
- See user name in top-right corner
- See all five tabs: Dashboard, Multi-Cloud, Kubernetes, Reports, Developer
- Click "Multi-Cloud" tab → see cloud provider configuration form
- Click "Developer" tab → see system settings
- Click logout → return to login page
- See user name in top-right corner
- See three tabs: Dashboard, Multi-Cloud, Reports
- NO Kubernetes tab
- NO Developer tab
- Can configure cloud providers in Multi-Cloud tab
- See user name in top-right corner
- See two tabs: Dashboard, Kubernetes
- NO Multi-Cloud tab
- NO Reports tab
- NO Developer tab
- See user name in top-right corner
- See only Dashboard tab
- NO Multi-Cloud, Kubernetes, Reports, or Developer tabs
- Login successfully
- Leave idle for 1 hour (or edit code to reduce timeout to 60 sec for testing)
- Automatic logout occurs
- Notification shows "Session expired due to inactivity"
- Redirected to login page
- Go to login page
- Try 5 incorrect password attempts
- On 5th attempt, see lockout message
- Must wait 20 minutes before trying again (or edit code to reduce timeout for testing)
- Login as admin or analyst
- Go to Multi-Cloud tab
- See credential entry form for AWS, Azure, GCP
- Form validation works (required fields, format validation)
- Can submit valid credentials or mock data
-
authenticate_user("admin", "admin_password")works -
authenticate_user("wrong", "wrong")fails -
has_permission("admin", "system:configure")returns TRUE -
has_permission("viewer", "system:configure")returns FALSE -
get_ui_visibility("admin")shows all features -
get_ui_visibility("viewer")hides most features
-
user_authenticated()is FALSE before login -
user_authenticated()is TRUE after login -
current_user_data()$usernameshows correct user -
current_user_data()$roleshows correct role
- Nav panels update based on role
- Nav_spacer() creates spacing before user menu
- User info header displays username and role
- Session timer runs every 60 seconds
- User is logged out after inactivity timeout
- Notification triggers before logout
- New login required after timeout
- Check username/password match demo users above
- Verify
RBAC_DB_PATHisNULLfor demo mode - Check RBAC modules are sourcing correctly
- Expected behavior based on role
- Verify correct user logged in
- Check
get_ui_visibility()inlib/rbac.R
-
Production Database
- Replace
RBAC_DB_PATH <- NULLwith actual file path - Run
setup/rbac_schema.sqlto create schema - Create real users with
create_user()
- Replace
-
API Integration
- Uncomment RBAC middleware in
api/plumber.R - Apply filters to all endpoints
- Test API authentication
- Uncomment RBAC middleware in
-
Add Permission Checks
- Add checks before sensitive operations:
- Cost export:
if (has_permission(..., "cost:export")) - User creation:
if (has_permission(..., "user:create")) - K8s config:
if (has_permission(..., "cluster:configure"))
- Cost export:
- Add checks before sensitive operations:
-
Customize Appearance
- Edit
lib/login_ui.Rfor custom branding - Update
lib/rbac.Rwith custom roles/permissions - Modify role colors in badge display
- Edit
-
Audit Monitoring
- Set up log monitoring from
audit_logtable - Create reports from role_changes table
- Alert on suspicious activity patterns
- Set up log monitoring from
Expected Outcome: CloudPulse now supports enterprise multi-user access with role-based features