A full-stack finance/equity application for learning Gitpod and dev containers.
Follow the comprehensive workshop guide in WORKSHOP.md to learn:
- Frontend: React + Vite (Port 3000)
- Backend: Node.js + Express (Port 3001)
- Database: SQLite (better-sqlite3) - Embedded database stored in
backend/portfolio.db
workshop/
βββ .devcontainer/
β βββ devcontainer.json # Dev container configuration
β βββ Dockerfile # Container image definition
βββ .ona/
β βββ automations.yaml # Ona automations configuration
βββ backend/
β βββ server.js # Express API server
β βββ init-db.js # Database initialization
β βββ package.json # Backend dependencies
βββ frontend/
β βββ src/
β β βββ App.jsx # Main React component
β β βββ components/ # React components
β β βββ index.css # Styles
β βββ index.html # HTML entry point
β βββ vite.config.js # Vite configuration
β βββ package.json # Frontend dependencies
βββ WORKSHOP.md # Workshop exercises
βββ README.md # This file
- Portfolio Management: Create and track investment portfolios
- Stock Trading: Buy and sell stocks with real-time calculations
- Performance Metrics: View gain/loss, returns, and portfolio value
- Transaction History: Complete audit trail of all trades
- Responsive Design: Works on desktop and mobile devices
# View automation status
gitpod automations service list
gitpod automations task list-executions
# Initialize/reset database
cd backend && node init-db.js
# Check running services
ps aux | grep node
# Test API
curl http://localhost:3001/api/health
# View database file
ls -lh backend/portfolio.dbGET /api/health- Health checkGET /api/portfolios- List all portfoliosGET /api/portfolios/:id- Get portfolio with holdingsGET /api/stocks- List all available stocksGET /api/portfolios/:id/transactions- Get transaction historyPOST /api/transactions- Create a new transactionPUT /api/stocks/:id/price- Update stock price
This is a workshop project. Feel free to fork and experiment!
MIT License - feel free to use this for learning and teaching.
Ready to start? Open WORKSHOP.md and begin with Exercise 1!