Current Environment & Deployment State
Last Updated: December 2, 2025
Purpose: Document the current state of environments, deployment workflow, and identify gaps for pipeline improvements.
Table of Contents
- Environment Summary
- Local Development
- Test Environment
- Production Environment
- External Services by Environment
- Current Deployment Workflow
- Gaps & Risks
Environment Summary
| Environment |
Status |
Database |
Hosts |
Purpose |
| Development |
✅ Active |
alumni_lookup_development (local PG) |
lookup.bualum.dev:3000, champions.bualum.dev:3000 |
Local coding/testing |
| Test |
✅ Active |
alumni_lookup_test (local PG) |
localhost:3000 |
Minitest suite (241 tests) |
| Staging |
❌ None |
— |
— |
No staging environment exists |
| Production |
✅ Active |
Heroku Postgres |
lookup.bualum.co, champions.bualum.co |
Live users |
Local Development
How to Run
# Standard start (uses foreman + Procfile.dev)
bin/dev
# This runs:
# - Rails server with SSL on port 3000
# - Tailwind CSS watcher
Configuration
| Aspect |
Details |
Source |
| Procfile |
Procfile.dev |
Uses SSL with local certs |
| Process Manager |
Foreman |
Installed via bin/dev if missing |
| Port |
3000 |
Default via $PORT |
| SSL Certs |
champions.bualum.dev.pem, champions.bualum.dev-key.pem |
Local SSL for subdomain testing |
| Subdomains |
lookup.bualum.dev, champions.bualum.dev |
Configured in config.hosts |
| TLD Length |
1 |
Set in development.rb for .dev domain |
Database
- Adapter: PostgreSQL
- Database:
alumni_lookup_development
- Connection: Local socket (no host/port by default)
- Pool: 3 threads
External Services in Development
| Service |
Behavior |
Configuration |
| Email |
Letter Opener (opens in browser) |
delivery_method: :letter_opener |
| File Storage |
Local disk (storage/) |
active_storage.service: :local |
| Cloudinary |
Not used |
— |
| CRM/Salesforce |
No live integration |
Contact ID field exists but export-only |
Required Local Setup
- PostgreSQL running locally
- VIPS library for image processing (
brew install vips)
- Local SSL certificates for subdomain testing
/etc/hosts entries for *.bualum.dev → 127.0.0.1
Test Environment
How to Run
# Full test suite
rails test
# Specific file
rails test test/models/alumni_test.rb
# Specific test
rails test test/models/champion_signup_test.rb:4
Configuration
| Aspect |
Details |
Source |
| Framework |
Minitest |
Rails default |
| Test Count |
241 tests, 573 assertions |
See TESTING_GUIDE.md |
| CI Eager Load |
ENV["CI"].present? |
test.rb line 17 |
| Fixtures |
test/fixtures/ |
10+ fixture files |
Database
- Database:
alumni_lookup_test
- Behavior: Wiped and recreated between test runs
- Transactions: Tests run in transaction blocks (rolled back)
External Services in Test
| Service |
Behavior |
Configuration |
| Email |
Test adapter (no delivery) |
delivery_method: :test |
| File Storage |
Temp disk (tmp/storage) |
active_storage.service: :test |
| Caching |
Null store |
cache_store: :null_store |
Production Environment
Hosting
| Aspect |
Details |
| Platform |
Heroku |
| App Name |
alumni-lookup |
| Dyno Type |
2x Web (1 dyno, ~$0.069/hr) |
| Database |
Essential 0 (~$0.007/hr) |
Processes
| Process |
Command |
Source |
| web |
bundle exec puma -C config/puma.rb |
Procfile |
Configuration
| Setting |
Value |
Source |
| RAILS_MAX_THREADS |
3 |
deploy_memory_fix.sh |
| WEB_CONCURRENCY |
1 |
deploy_memory_fix.sh |
| RAILS_LOG_LEVEL |
info |
deploy_memory_fix.sh |
| Force SSL |
true |
production.rb |
Database
- Provider: Heroku Postgres
- Plan: Essential 0 (~$0.007/hr, 1GB storage, 20 connections)
- Connection Pool: 3 (matches RAILS_MAX_THREADS)
- Backups: ❓ Need to configure (see operations docs)
External Services in Production
| Service |
Provider |
Env Vars |
Status |
| Email |
Mailgun |
MAILGUN_API_KEY, MAILGUN_DOMAIN, MAILGUN_API_HOST |
✅ Configured |
| File Storage |
Cloudinary |
CLOUDINARY_URL |
✅ Configured |
| CRM |
Salesforce |
None (export-only via Contact ID) |
✅ One-way export |
| Logging |
Heroku Logs |
— |
✅ Default |
| Monitoring |
❓ |
— |
Not confirmed |
Domains
| Subdomain |
Purpose |
DNS |
lookup.bualum.co |
Internal staff portal |
Points to Heroku |
champions.bualum.co |
External champion signup |
Points to Heroku |
External Services by Environment
| Service |
Development |
Test |
Production |
| Email |
Letter Opener |
Test adapter |
Mailgun API |
| Storage |
Local disk |
Temp disk |
Cloudinary |
| Database |
Local Postgres |
Local Postgres |
Heroku Postgres |
| CRM/Salesforce |
No integration |
No integration |
Export-only (Contact ID) |
| SSL |
Local certs |
None |
Heroku ACM |
| Caching |
Optional (null by default) |
Null store |
Memory store (64MB) |
Current Deployment Workflow
“Blind Push to Production” (Current)
┌─────────────────┐
│ Local Dev │
│ (bin/dev) │
└────────┬────────┘
│ git commit + push
▼
┌─────────────────┐
│ main branch │
│ (GitHub) │
└────────┬────────┘
│ git push heroku main
▼
┌─────────────────┐
│ Production │◄── No staging, no gates
│ (Heroku) │
└─────────────────┘
Deployment Commands (Current)
# Typical deploy
git push heroku main
heroku run rails db:migrate
# Or via deploy_memory_fix.sh (includes config vars)
./deploy_memory_fix.sh
Post-Deploy Verification (Manual/Ad-Hoc)
No formal smoke test checklist exists. Staff manually verify:
- Site is accessible
- Can log in
- Basic search works
Gaps & Risks
🔴 Critical Gaps
| Gap |
Risk |
Impact |
| No Staging Environment |
Breaking changes hit production immediately |
High - user-facing bugs |
| No CI Pipeline |
Tests not run on every push/PR |
High - regressions slip through |
| No Deploy Gates |
Deploys proceed without test verification |
High - broken deploys |
| No Smoke Test Checklist |
Post-deploy validation is ad-hoc |
Medium - issues discovered late |
🟡 Moderate Gaps
| Gap |
Risk |
Impact |
| No Rollback Plan |
Slow recovery from bad deploys |
Medium - extended downtime |
| Manual Migrations |
Forgotten migrations or wrong order |
Medium - data issues |
| No Review Apps |
Can’t preview PR changes live |
Low - dev friction |
| Limited Monitoring |
Heroku logs only, no APM |
Low - slow incident response |
🟢 In Good Shape
| Aspect |
Status |
Details |
| Test Suite |
✅ |
241 tests, 573 assertions, 0 failures |
| Documentation |
✅ |
Comprehensive docs in /docs |
| Role-Based Access |
✅ |
Admin/Staff fully enforced |
| Two-Domain Architecture |
✅ |
lookup + champions working |
| External Services |
✅ |
Mailgun, Cloudinary configured |
Confirmed Details
| Question |
Answer |
| Heroku App Name |
alumni-lookup |
| Dyno Plan |
2x Web (1 dyno, ~$0.069/hr) |
| Database Plan |
Essential 0 (~$0.007/hr) |
| GitHub Actions |
✅ Available |
| DNS Management |
Owner-managed |
| Staging Usage |
Light — sanity testing only |