FFFF GitHub - sechmann/googvarm · GitHub
[go: up one dir, main page]

Skip to content
sechmannPublic

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Repository files navigation

Go' og varm

A Prettynice/Gren site for the Go' og varm farm shop.

Development

Install the tools (Node 20 and the ws4sqlite database binary, see mise.toml):

mise install

Then install the JS dependencies (Prettynice, Gren, nodemon) from package-lock.json, e.g. npm ci.

Start the local database bridge and web server:

mise run dev

Run the end-to-end smoke test (builds first, uses its own temporary database and ports, never touches db/googvarm.db):

mise run test

Build the app:

mise run build

Run the built server:

mise run start

Configuration

Environment variables (see server/src/Config.gren): ADMIN_PASSWORD (required for login, min 12 chars; mise run dev defaults it to dev-admin-password), HOST, PORT, DB_URL, COOKIE_SECURE, SESSION_TTL_DAYS.

Production

Runs on NixOS via the flake in this repo: see nix/README.md (module, Caddy/HTTPS, backups, monitoring). GET /healthz reports app + DB health.

Code Layout

Server-side Gren lives in server/src.

Main.gren wires authentication, route dispatch, and page loading together. Route parsing is in Routes.gren, shared response/layout helpers are in Responses.gren, and admin course form parsing is in CourseForm.gren.

Views.gren contains ordinary static pages, while CourseViews.gren owns the course listing and admin course dialog markup.

Client-side Prettynice components live in client/src/Components.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages

0