BikeControl (SwiftControl)
Use Zwift Click, Zwift Play, Shimano Di2, or any Bluetooth controller with MyWhoosh, Rouvy, Zwift, and more. Free to try on iOS, Android, Windows, and macOS.
BCC CVote — Cricket Captain Availability Voting
Translation pending
Sports & fitnessPython · JavaScriptGitHub @Vennu04OnlineOwner unconfirmed
Have you tried it? One tap is enough. No sign-in needed.
No updates detected yet. GitHub releases will appear here.
Owners of public repositories under a personal GitHub account can sign in to verify ownership and manage the introduction themselves. No administrator approval is needed.
Sign in, generate a verification file, and commit it to this repository’s default branch within 30 minutes. Files on other branches or forks do not count. Then check the file below to manage the project without administrator approval. Keep the file to retain your access.
If needed, you will go to sign-in. After signing in, return here and press your chosen verification button again.
Run /nomorevibe verify in your project folder to verify ownership and manage the introduction yourself.
Verify in one minuteAsk about other verification options
Cricket Captain Availability Voting App
Translation pending
Taken from the repository README
Loading the full README. The saved excerpt is shown below.
Cricket club app for weekend match-availability voting and a live points-based player
auction to split available players into two balanced teams. Currently running the BCC
Premier League 2026 tournament.
Live: https://bcccvote.duckdns.org/
Deployment/ops details: see INFRASTRUCTURE.mdRead the full README ↗Cricket club app for weekend match-availability voting and a live points-based player auction to split available players into two balanced teams. Currently running the BCC Premier League 2026 tournament.
Live: https://bcccvote.duckdns.org/ Deployment/ops details: see INFRASTRUCTURE.md
organizer role gets full admin-console access
except the handful of destructive actions (delete captain/player, reset-device,
close-window-early), which stay admin-only. A new read-only viewer role can see
results/leaderboard but has no vote/bid/admin rights at all.audit_logs
collection (user_id, action, entity_type, entity_id, old_value, new_value,
timestamp), alongside the existing specialized trails (vote overrides, auction
release log, proxy-bid/drop chat notes), which are unchanged.| Layer | Tech |
|---|---|
| Frontend | React 18 + Vite + Tailwind CSS + React Router v6 + Axios, PWA (vite-plugin-pwa) |
| Backend | Flask 3 + PyMongo + flask-jwt-extended + gunicorn (2 sync workers), pytz (IST) |
| Database | MongoDB Atlas (M0 free tier) |
| Prod infra | Single EC2 instance, Docker Compose (Caddy + backend + frontend) — no Kubernetes. See INFRASTRUCTURE.md |
| CI/CD | GitHub Actions, OIDC deploy role (no static AWS keys), deploy via SSM RunCommand |
| Container registry | AWS ECR |
| Weather | OpenWeatherMap free tier (5-day/3-hour forecast), cached in Mongo (2h TTL, 10min on failure) |
| PWA | vite-plugin-pwa, autoUpdate registration — installable, app-shell precached, API calls never cached |
git clone https://github.com/Vennu04/BCC-CVote
cd BCC-CVote
docker-compose up -d
docker-compose run --rm seed # first time only — seeds 4 slots + admin + sample captains
ADMIN / admin@bcc2024 (seed default)MI → mi)Stop: docker-compose down
Deployment, AWS architecture, CI/CD pipeline details, and secrets management are all in INFRASTRUCTURE.md — kept separate from this file since they change independently of the app's own features.
category_total // 2, recomputed live from that slot's actual confirmed voters).linked_captain_id on their
admin account, set by hand for the small number of dual-role admins who need it.For the real-world case where a captain/player confirmed availability by phone/WhatsApp but couldn't cast (or fix) their own vote in the app in time.
POST /admin/votes sets or changes anyone's vote for any slot; DELETE /admin/votes/<slot_id>/<user_id> clears one. Both are admin-only and deliberately bypass
the self-service rules in votes.py (window must be open to vote at all; a short
emergency-revoke deadline after close). Works identically for the 4 fixed slots and any
ad-hoc match.vote_overrides collection (admin,
target person, slot, old → new availability, timestamp).0/O/1/l/I), sets the
forced-change flag, logs who reset whose password and when, and gives admin a
copy-to-clipboard button on the generated password instead of retyping it from a toast.token_version counter embedded in its JWT;
changing a password bumps it, instantly invalidating every other active session for that
account — including a hijacked one — without needing server-side token storage.DEVICE_LOCK_ENABLED — currently disabled for all users (a deliberate config choice,
not a temporary testing state) so players can use the app across multiple devices of their
own.is_player=True so that
same login can also cast an availability vote — counted in the dashboard/summary/exports/
auction pool like any other voter.is_admin=True without changing their role or login —
checked via admin_required's {"role": "admin"} OR {"is_admin": True}. A linked_captain_id
then ties such an account to the real captain record it corresponds to, so it can be blocked
from running an auction it would also be bidding in (see Auction rules).A separate tracking system from match-slot voting — this is about real-world season attendance, used to decide who's eligible once the league stage ends and a knockout round begins.
matches_present / total_matches) is recomputed immediately on every
+1 click, and is what ranks and highlights the list.knockout_eligible in one click; admin can hand-adjust individual checkboxes after.
Bulk edits show an "Unsaved changes" indicator and warn before an accidental refresh/close
discards them.knockout_eligible doesn't gate voting or auction participation.gzip_proxied had to be set explicitly since nginx doesn't compress proxied /api/
responses by default even with gzip on.team_code being attacked rather than caller IP (this app sits behind CloudFront → Caddy
with no verified trusted-proxy chain, so IP-keying would be unreliable). Backed by
MongoDB (flask-limiter + the limits library's Mongo storage), not in-memory.backend/app/indexes.py (single source of truth, also used by scripts/seed.py),
applied idempotently on every app boot.React.lazy in App.jsx) — a captain never downloads
the 5 admin pages' code and vice versa; only Login/ResetPassword stay eagerly loaded.$in queries instead of N per-slot round trips, since this endpoint is polled every 5-10s
from two different admin pages.Sentry.ErrorBoundary) and
backend (Flask integration) and already deployed, but currently inert — no DSN is
configured yet. Both sides no-op safely without one.BCC-CVote/
├── backend/
│ ├── app/
│ │ ├── __init__.py # Flask app factory, blueprint registration
│ │ ├── config.py
│ │ ├── indexes.py # single source of truth for Mongo indexes — also used by scripts/seed.py
│ │ ├── routes/
│ │ │ ├── auth.py # /api/auth/* — login, device binding, change-password
│ │ │ ├── votes.py # /api/slots, /api/votes/* — self-service voting + named per-slot attendance
│ │ │ ├── admin.py # /api/admin/* — captains/players, windows, ad-hoc slots,
│ │ │ │ # admin vote override, attendance/knockout tracking,
│ │ │ │ # reset-device/reset-password, exports
│ │ │ └── auction.py # /api/admin/auction/*, /api/auction/* — live + practice auctions, chat
│ │ ├── services/weather.py # OpenWeatherMap call + Mongo-cached forecast lookup
│ │ └── utils/
│ │ ├── auth.py # JWT decorators + token_version session-invalidation check
│ │ ├── passwords.py # shared password validation + temp-password generation
│ │ ├── time_utils.py # IST timezone helpers, voting-window logic
│ │ └── export.py # CSV/Excel report builders
│ ├── scripts/ # seed.py + one-off migrations (credential regen, roster
│ │ # sync, admin-access grants — see Accounts & security)
│ ├── tests/ # pytest — auth, auction lifecycle, password/device security,
│ │ # admin vote override, attendance
│ ├── Dockerfile, gunicorn.conf.py, run.py
├── frontend/
│ ├── src/
│ │ ├── pages/
│ │ │ ├── Login.jsx, ResetPassword.jsx # public self-service reset form
│ │ │ ├── CaptainDashboard.jsx, PlayerDashboard.jsx, Results.jsx, Auction.jsx
│ │ │ ├── ChangePassword.jsx # forced/self-service password change
│ │ │ └── admin/
│ │ │ ├── AdminDashboard.jsx # captain×slot grid + per-slot "yet to vote" mark-vote panel
│ │ │ ├── ManagePlayers.jsx # captains + players, merged into one page
│ │ │ ├── VotingWindow.jsx # "Add Ad-hoc Match" form + Confirmed/Pending turnout
│ │ │ ├── Attendance.jsx # +1 attendance credit + knockout-eligibility ranking
│ │ │ └── Auction.jsx # auction setup + live control screen
│ │ ├── components/ # Navbar, SlotCard, VotingSlots, WeatherForecast, Footer,
│ │ │ # AuctionRulesNote, AuctionChat, PasswordInput,
│ │ │ # PageBackgroundPhoto, LoadingState, ConfirmDialog,
│ │ │ # ConfirmedPlayersPanel, YetToVotePanel
│ │ ├── hooks/ # useVoting.js, useAuction.js (2.5s polling), useConfirm.js
│ │ ├── context/AuthContext.jsx # sessionStorage-based — per-tab login isolation
│ │ ├── config/appMeta.js # app name/version, tournament name, company name
│ │ ├── utils/ # api.js, device.js, roles.js, formatDate.js, pwaUpdate.js
│ │ └── App.jsx
│ ├── Dockerfile, nginx.conf, vite.config.js # vite-plugin-pwa (autoUpdate)
├── deploy/ # docker-compose.prod.yml, Caddyfile, deploy.sh — see INFRASTRUCTURE.md
├── terraform-new-account/ # current prod infra (EC2, ECR, SSM, IAM) — see INFRASTRUCTURE.md
├── terraform/ # RETIRED — old (decommissioned) account, kept for history only
└── .github/workflows/
├── dev-ci.yml
└── prod-cd-newaccount.yml # the only prod deploy pipeline
DEVICE_LOCK_ENABLED=false) — see
Accounts & security. No end date set; check with the team before
re-enabling.sentry-dsn SSM parameter and a VITE_SENTRY_DSN GitHub Actions secret.league_matches collection, /admin/attendance/ matches/* routes) is retired from the frontend but not removed from the backend — low
priority, not causing any issue, just unused code.backend/tests/).[email protected]) to check
for an unlisted org-tier API; no automated integration built yet.is_test auction with
any two captains and any hand-picked roster, not tied to a real match slot or voting
window, so captains can rehearse the live-bidding flow (including chat) before it matters.
Uses every other auction route unmodified; only creation has its own path./reset-password