summaryrefslogtreecommitdiff
path: root/yhttpd/src/wrap.h
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-07-02 10:01:50 +0300
committerPaul Buetow <paul@buetow.org>2026-07-02 10:01:50 +0300
commit67babb244b8ab6fcdfe3748b1c52fcac60eb2ed4 (patch)
tree88c40aff603237cb5eacc9fbc76de8b56d7aaff1 /yhttpd/src/wrap.h
parent462e4ac6995760646b53e110f2662a6cd14fc882 (diff)
ychat: remove the no-database build option (task es0)
DATABASE/SQLite is no longer optional. src/configure.ac and the generated src/configure now check sqlite3.h/-lsqlite3 unconditionally, the same way pthread/libevent already were, right after those checks (matching order in both files) - there's no --enable-sqlite opt-in any more, and configure aborts via header_error/lib_error if SQLite isn't available rather than silently producing the old in-memory-only, no-account "Mode A" guest chat. --enable-mysql is left alone (pre-existing, separately broken, out of scope - this is about ychat always having *a* database, not about MySQL). With DATABASE guaranteed, the three recent no-DB-build UI special-cases (651f762, 0cdec77, 6c3a65b) are dead code, so they're reverted: deleted html/index_guest.html, reverted html/input.html + src/reqp.cpp to always render a static Options link (dropped the #ifdef DATABASE/%%OPTIONS_LINK%% templating), and the Dockerfile no longer strips register.html/options.html or their .so modules. Unregistered guest chatting itself is untouched - chat.enableguest is a runtime config toggle independent of the compile-time database requirement, and a guest's is_reg is still always false so a guest can never claim operator via chat.defaultop. Consolidated the two Dockerfiles into one (SQLite-backed; deleted Dockerfile.sqlite) and merged DOCKER.md/DOCKER-SQLITE.md into a single DOCKER.md. Updated root README.md and etc/ychat.conf's option descriptions to stop claiming the no-DB build is live/default. Verified in a Rocky Linux 9 podman container: index.html has the password field + Register link, register.html/options.html both resolve, POSTing to register.html creates a SQLite user row, wrong password is rejected and the correct one logs in, the same account's login still works identically after a full container restart with /app/data bind-mounted (persistence), and unregistered guest login still works. Independently reproduced by a fresh-context review agent, which also rebuilt + re-verified the whole flow itself and caught one real (if harmless) issue - the generated src/configure had the SQLite check in a different physical position than configure.ac's - now fixed so both files agree on ordering. Not deployed to f3s: the live cluster still runs the old no-DB image. Rolling this out needs a persistent volume for /app/data and an updated Helm chart - a deliberate follow-up, not done here. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Diffstat (limited to 'yhttpd/src/wrap.h')
0 files changed, 0 insertions, 0 deletions