Phoenix + LiveView app for basketball prospect discovery, card browsing, and reviews.
- Elixir / OTP
- Phoenix 1.7 + Phoenix LiveView
- Ecto + PostgreSQL
- Tailwind + esbuild
- Supabase (auth/data integration)
- Fly.io deployment
- Elixir
~> 1.14 - Erlang/OTP compatible with your Elixir version
- PostgreSQL (local or hosted)
- Node.js/npm (for frontend assets)
- Install dependencies and bootstrap project:
mix setup
- Create your local env file:
cp .env.example .env- On PowerShell:
Copy-Item .env.example .env
- Fill in
.envvalues for your local environment. - Start Phoenix:
mix phx.server- or
iex -S mix phx.server
- Open
http://localhost:4000.
To create the schema from scratch on a new machine:
- Copy env file and set DB URL:
cp .env.example .env- On PowerShell:
Copy-Item .env.example .env - Make sure
SUPABASE_DATABASE_URLpoints to your local Postgres DB.
- Run full setup:
mix setup
This runs:
mix ecto.createmix ecto.migratemix run priv/repo/seeds.exs
If you want to rebuild DB from zero at any time:
mix ecto.reset
Use .env.example as the source of required keys.
SUPABASE_ANON_KEY: public anon key used by frontend auth flowSUPABASE_DATABASE_URL: DB connection URL used by EctoSUPABASE_JWT_SECRET: JWT signer secret (server-side only)SUPABASE_URL: Supabase project URL (DEV_MODEfor local setup in this repo)SUPABASE_SERVICE_ROLE_KEY: service-role key (server-side only)SECRET_KEY_BASE: Phoenix secret key basePHX_HOST: external hostnamePORT: app portPOOL_SIZE: Ecto DB pool size
mix setup: deps + db setup + asset buildmix phx.server: run web servermix test: run test suitemix ecto.reset: drop + recreate + migrate + seedmix assets.deploy: minify assets and digest for production
This repo includes Fly.io config:
- App runtime config:
config/runtime.exs - Fly config:
fly.toml - CI deploy workflow:
.github/workflows/fly-deploy.yml
For GitHub Actions deploy, set repository secret:
FLY_API_TOKEN
- Never commit
.envor real credentials. - Keep
SUPABASE_SERVICE_ROLE_KEY,SUPABASE_JWT_SECRET, andSECRET_KEY_BASEserver-side only. - Use platform secrets (GitHub/Fly) for production.