One-shot deploy for fresh Ubuntu 24.04 root SSH: curl -fsSL https://gitea.ahkhan.me/apps/quiz/raw/branch/master/deploy/bootstrap.sh | bash bootstrap.sh: idempotent stage-by-stage installer for Caddy, Python venv, quiz system user, repo clone to /opt/quiz, env-var prompts, systemd unit, Caddyfile, and a healthz check. Reattaches /dev/tty so curl|bash can read the admin password interactively. quiz.service: uvicorn under the quiz system user (no shell, no SSH), ProtectSystem=full, ProtectHome=true, PrivateTmp=true, NoNewPrivileges=true. Caddyfile.tpl: reverse_proxy 127.0.0.1:8001 with auto Let's Encrypt; DOMAIN substituted at install time. examples/pool_example.json: generic demo pool, schema reference only. README rewritten around the deploy flow + class-day lifecycle.
32 lines
687 B
JSON
32 lines
687 B
JSON
{
|
|
"title": "Demo Pool: Generic Knowledge",
|
|
"score_fn": "linear_decay",
|
|
"time_limit_default": 60,
|
|
"questions": [
|
|
{
|
|
"id": "demo1",
|
|
"text": "Which of these is a programming language?",
|
|
"options": {
|
|
"A": "HTTP",
|
|
"B": "Python",
|
|
"C": "TCP",
|
|
"D": "DNS"
|
|
},
|
|
"correct": "B",
|
|
"explanation": "Python is a general-purpose programming language; the others are network protocols."
|
|
},
|
|
{
|
|
"id": "demo2",
|
|
"text": "What is 2 + 2?",
|
|
"options": {
|
|
"A": "3",
|
|
"B": "4",
|
|
"C": "5",
|
|
"D": "22"
|
|
},
|
|
"correct": "B",
|
|
"explanation": "Basic arithmetic."
|
|
}
|
|
]
|
|
}
|