A production-ready platform for running internal company hackathons. Built with Go and Buffalo framework for high performance and reliability.
🚀 Launch Internal Hackathons in Minutes Create and manage hackathon events for your organization with a single deployment. No complex configuration required - just set up, invite employees, and start innovating.
👥 Built for Company Teams Seamless team formation across departments with automatic membership tracking. Employees can create projects, join teams, and collaborate with built-in presentation management.
🔒 Enterprise-Grade Security Complete audit logging tracks every action. Role-based access control, CSRF protection, and bcrypt password hashing with per-user salts keep your internal data secure.
📊 Powerful Admin Dashboard Monitor everything from a central dashboard. Manage employees, track projects, view audit logs, and configure platform settings - all from one place.
🎯 Self-Hosted & Open Source Keep your hackathon data within your organization. Deploy on your own infrastructure with full control over your intellectual property and project submissions.
💻 Developer Friendly Clean repository pattern, comprehensive Makefile with 25+ commands, hot reload for development, and extensive documentation make customization straightforward.
- Features
- Screenshots
- Quick Start
- Docker Deployment
- Project Structure
- Testing
- CI/CD
- Contributing
- License
- User Registration - Create accounts with email validation and password policy enforcement
- Secure Authentication - bcrypt password hashing with per-user salts and session management
- User Profiles - Personal profiles with name, email, company/team, and role information
- Profile Editing - Users can update their personal information and change passwords
- Password Reset - Forced password reset functionality for new accounts
- Role-Based Access - Two-tier system with Owner (admin) and Hacker (participant) roles
- Hackathon Creation - Owners can create hackathons with title, description, dates, and status
- Schedule Management - Add rich-text schedules with HTML formatting support (nullable field support)
- Status Tracking - Four status types: upcoming, active, completed, and hidden
- Hackathon Listing - Browse all hackathons with filtering and pagination
- Detailed Views - Individual hackathon pages with statistics, timeline, and project listings
- Owner Controls - Edit and delete hackathons (owner-only)
- Project Creation - Users can create one project per hackathon with name, description, and links
- Project Images - Upload and manage project images stored in database
- Team Formation - Project membership system allowing users to join teams
- Join/Leave Projects - Users can join projects and owners can manage memberships
- Unique Constraints - Prevents users from creating multiple projects per hackathon
- Team Member Display - Shows all team members with roles (owner/member) and join timestamps
- Presentation Opt-In - Projects can toggle presentation status with order tracking
- File Uploads - Upload files associated with hackathons and projects
- Database Storage - Files stored as binary data in PostgreSQL with metadata
- File Download - Secure file retrieval with proper content-type headers
- File Management - View, list, and delete uploaded files
- Access Control - File operations restricted to authenticated users
- Comprehensive Overview - Statistics on users, hackathons, projects, and audit events
- User Management - View, create, edit, and delete user accounts
- Role Assignment - Promote/demote users between owner and hacker roles
- Account Protection - Prevents deletion of owner accounts to maintain system access
- Force Password Reset - Require users to change passwords on next login
- Hackathon Overview - Admin view of all hackathons across the platform
- Project Monitoring - View all projects with filtering and search
- Audit Logs - Complete activity log with user actions, timestamps, and IP addresses
- Presentations Dashboard - Track all projects opting to present with order management
- System Configuration - Password policies and platform settings management
- Comprehensive Audit Logging - All user actions logged with timestamps, IP addresses, and user agents
- Password Policies - Configurable minimum length, uppercase, numbers, and special character requirements
- CSRF Protection - Built-in Cross-Site Request Forgery protection on all forms
- Session Security - Secure session handling with proper authentication checks
- Owner Protection - Prevents accidental lockouts by protecting admin accounts
- Input Validation - Server-side validation for all forms and data entry
- SQL Injection Protection - Parameterized queries via Pop ORM
- Responsive Design - Mobile-friendly layout that works on all screen sizes
- Modern UI - Professional interface with sticky navigation and clean styling
- Bootstrap 5 - Clean, consistent styling with Bootstrap components
- Font Awesome Icons - Rich iconography throughout the interface
- Flash Messages - User feedback for all actions (success, error, info)
- Pagination - Efficient browsing of large datasets
- Custom Branding - Professional favicon with "H" logo and custom styling
- Inline Forms - Seamless inline editing and interactions
- Buffalo Framework - Built on Go Buffalo for high performance
- PostgreSQL Database - Robust relational database with UUID support
- Pop ORM - Database migrations and model management
- Docker Support - Full containerization with docker-compose
- Asset Pipeline - Webpack for CSS/JS bundling and optimization
- RESTful API - Clean URL structure and HTTP methods
- Repository Pattern - Clean architecture with repository interfaces
- Comprehensive Makefile - Developer-friendly commands for all operations
Here are some screenshots of the hackathon management platform:
Landing page with authentication options and platform overview
Browse all available hackathons with status indicators and filtering
Individual hackathon view with projects, schedule, and team information
Comprehensive admin panel with user management, audit logs, and system configuration
- Go (version 1.25 or later)
- Node.js (version 18 or later)
- Yarn (version 1.x)
- PostgreSQL (version 15 or later)
- Docker and Docker Compose (for containerized deployment)
# Clone the repository
git clone https://github.com/arxdsilva/hackathon.git
cd hackathon
# Complete project setup (recommended)
make setup
# Or set up manually:
make install # Install dependencies
make db-docker-up # Start PostgreSQL with Docker
make db-setup # Set up database
make db-migrate # Run migrations
make assets-dev # Build assets# Start development server
make dev
# Run unit tests (fast, no database)
make test-unit
# Run full test suite
make test-full
# View all available commands
make helpThis project includes a comprehensive Makefile with common development commands:
# Development
make dev # Start development server
make build # Build for production
make run # Run production build
# Testing
make test-unit # Run unit tests (fast, no DB)
make test # Run all tests
# Database
make db-setup # Set up development database
make db-migrate # Run migrations
make db-reset # Reset database
make db-docker-up # Start DB with Docker
# Assets
make assets-dev # Build assets with watch mode
make assets-build # Build production assets
# Code Quality
make fmt # Format Go code
make vet # Run go vet
make lint # Run linter
# Docker
make docker-build # Build Docker image
make docker-dev # Start full dev environment
# Utilities
make status # Show environment status
make clean # Clean build artifacts
make help # Show all commandsInstall Go dependencies:
go mod downloadInstall Node.js dependencies:
yarn installCreate a PostgreSQL database for the application. You can use the provided Docker setup or set up PostgreSQL locally.
# Start PostgreSQL in Docker
docker run --name hackathon-postgres -e POSTGRES_PASSWORD=postgres -e POSTGRES_USER=postgres -p 5432:5432 -d postgres:15-alpine
# Initialize the database with the schema
docker exec -i hackathon-postgres psql -U postgres -d postgres < init-db.sqlCreate a database named hackathon_development and run the initialization script:
CREATE DATABASE hackathon_development;
\c hackathon_development;
\i init-db.sql;The application uses the following environment variables (defaults are provided for development):
GO_ENV=developmentDATABASE_URL=postgres://postgres:postgres@localhost:5432/hackathon_development?sslmode=disablePORT=3000LOG_LEVEL=debug
You can override these by creating a .env file or setting them in your shell.
# Run migrations to set up the database schema
buffalo db migrate upbuffalo devThe application will be available at http://127.0.0.1:3000.
For production deployment or isolated development environment, use Docker Compose:
# Build the application
docker-compose build
# Start all services (PostgreSQL + App)
docker-compose up -d
# View logs
docker-compose logs -f appThe application will be available at http://localhost:3000.
# Stop services
docker-compose down
# Rebuild after code changes
docker-compose build --no-cache
# View logs for specific service
docker-compose logs postgres
docker-compose logs app
# Access database directly
docker-compose exec postgres psql -U postgres -d hackathon_developmentbuffalo dev- Start development server with hot reloadbuffalo build- Build the application binarybuffalo db migrate up- Run database migrationsbuffalo db migrate down- Rollback migrationsbuffalo db migrate status- Check migration statusbuffalo routes- List all application routes
yarn build- Build production assetsyarn dev- Watch and rebuild assets during development
├── actions/ # Buffalo actions (controllers)
├── models/ # Database models with audit logging
├── templates/ # Plush templates with responsive layouts
├── assets/ # CSS, JS, and image assets
├── migrations/ # Database migrations including audit_logs
├── public/ # Static files including custom favicon
├── docs/ # Documentation and screenshots
│ └── screenshots/ # Application screenshots
├── grifts/ # Buffalo tasks
├── config/ # Application configuration
├── docker-compose.yml # Docker services configuration
└── init-db.sql # Database initialization script
The application includes comprehensive unit tests to ensure code quality and functionality.
- Unit Tests: Pure business logic tests that don't require database connections
- Mock-Based Tests: Repository interface tests using generated mocks
- Validation Tests: Business logic validation without external dependencies
Unit tests test business logic in isolation and can be run without any database setup:
# Run all unit tests (no database required)
go test ./actions -v
# Run tests with coverage
go test ./actions -cover
# Generate coverage report
go test ./actions -coverprofile=coverage.out
go tool cover -html=coverage.out -o coverage.html
# Run all tests
go test ./...Tests are organized by functionality in corresponding <filename>_test.go files:
auth_test.go- Authentication testsusers_test.go- User management testsprofile_test.go- Profile display testsadmin_test.go- Admin functionality testsfiles_test.go- File management testspages_test.go- Public pages testsproject_memberships_test.go- Project membership testscompany_configurations_unit_test.go- Configuration validation testsrepository_mock_example_test.go- Mock usage examples
Unit tests run completely independently without any external dependencies and provide fast feedback during development.
This project uses GitHub Actions for continuous integration. The CI pipeline automatically runs on every push and pull request to the main and develop branches.
- Unit Tests: Runs isolated unit tests that don't require a database connection
- Unit Tests: Run instantly without any setup (
go test ./actions -run "Test...") - CI: Handles unit tests automatically on every push/PR
The CI pipeline runs automatically when:
- Code is pushed to
mainordevelopbranches - Pull requests are opened against
mainordevelopbranches
- Unit tests run the same locally and in CI (no external dependencies)
- Fork the repository
- Create a feature branch
- Make your changes
- Run tests:
buffalo test - Submit a pull request
This project is licensed under the GNU General Public License v3.0. See the LICENSE file for details.