AnalogyIT is a static marketing website with a Netlify-ready ticketing workflow.
This project now uses Netlify Functions + Netlify Blobs for production ticket storage.
- Push this repo to GitHub.
- In Netlify: Add new site → import from Git.
- Build settings:
- Build command: (leave empty)
- Publish directory:
.
netlify.toml already configures:
- Functions directory:
netlify/functions - API redirect:
/api/*→/.netlify/functions/:splat
In Netlify dashboard: Site configuration → Environment variables
Add these:
TICKET_ADMIN_PASSWORD= your admin dashboard login passwordTICKET_ADMIN_TOKEN= a long random secret token (different from password)
Example token generation (local terminal):
openssl rand -hex 32After redeploy:
- Open
/submit-ticket.htmland create a ticket. - Open
/ticket-login.htmland sign in withTICKET_ADMIN_PASSWORD. - Open
/ticket-dashboard.htmland verify list/update/delete actions.
If you deploy again and see the same failure, the problem is usually runtime configuration in Netlify (not GitHub).
Check these in order:
- Environment variables are set on Netlify for this site
TICKET_ADMIN_PASSWORDTICKET_ADMIN_TOKEN- After changing env vars, trigger a new deploy (or clear cache + deploy).
- Functions are being built
- In Deploy logs, confirm Netlify detects
netlify/functionsand bundles functions.
- In Deploy logs, confirm Netlify detects
- Functions are reachable
- Visit
/.netlify/functions/auth(GET should return 405 "Method not allowed"). - If this returns 404, functions are not being published by the current deploy settings.
- Visit
- Redirect is active
/api/authshould route to/.netlify/functions/authvianetlify.toml.
- Domain points to the correct Netlify site/deploy
- Ensure you are not testing an older site, branch deploy, or cached custom domain.
Tip: GitHub's role here is mainly source hosting + webhook trigger. The live API behavior is controlled by Netlify build/runtime settings.
- Ticket data is stored server-side via Netlify Blobs (not browser localStorage).
- Dashboard access is controlled server-side through the auth function.
- For stronger security, add additional edge protection (e.g. Netlify access controls / Cloudflare Access) for admin routes.