Publik webbsajt för Bitborg. https://www.bitborg.se/
  • TypeScript 66.4%
  • Astro 19.6%
  • JavaScript 10.2%
  • SCSS 3.3%
  • Dockerfile 0.5%
Hitta en fil
Kodförråd filer (senaste incheckning först)
Filnamn Senaste incheckningsmeddelande Senaste incheckningsdatum
Bitborg Renovate e530fa647c
Alla kontroller lyckades
deploy / build-and-push (push) Successful in 2m35s
ci / ci (push) Successful in 5m32s
fix(deps): update non-major dependencies (#429)
This PR contains the following updates:

| Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) |
|---|---|---|---|
| [@astrojs/node](https://docs.astro.build/en/guides/integrations-guide/node/) ([source](https://github.com/withastro/astro/tree/HEAD/packages/integrations/node)) | [`11.1.12` → `11.1.14`](https://renovatebot.com/diffs/npm/@astrojs%2fnode/11.1.12/11.1.14) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@astrojs%2fnode/11.1.14?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@astrojs%2fnode/11.1.12/11.1.14?slim=true) |
| [@astrojs/sitemap](https://docs.astro.build/en/guides/integrations-guide/sitemap/) ([source](https://github.com/withastro/astro/tree/HEAD/packages/integrations/sitemap)) | [`3.7.4` → `3.7.6`](https://renovatebot.com/diffs/npm/@astrojs%2fsitemap/3.7.4/3.7.6) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@astrojs%2fsitemap/3.7.6?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@astrojs%2fsitemap/3.7.4/3.7.6?slim=true) |
| [@lucide/astro](https://lucide.dev) ([source](https://github.com/lucide-icons/lucide/tree/HEAD/packages/astro)) | [`1.72.0` → `1.78.0`](https://renovatebot.com/diffs/npm/@lucide%2fastro/1.72.0/1.78.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@lucide%2fastro/1.78.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@lucide%2fastro/1.72.0/1.78.0?slim=true) |
| [@playwright/test](https://playwright.dev) ([source](https://github.com/microsoft/playwright)) | [`1.65.0` → `1.65.1`](https://renovatebot.com/diffs/npm/@playwright%2ftest/1.65.0/1.65.1) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@playwright%2ftest/1.65.1?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@playwright%2ftest/1.65.0/1.65.1?slim=true) |
| [@typescript-eslint/parser](https://typescript-eslint.io/packages/parser) ([source](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser)) | [`8.72.2` → `8.74.0`](https://renovatebot.com/diffs/npm/@typescript-eslint%2fparser/8.72.2/8.74.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@typescript-eslint%2fparser/8.74.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@typescript-eslint%2fparser/8.72.2/8.74.0?slim=true) |
| [astro](https://astro.build) ([source](https://github.com/withastro/astro/tree/HEAD/packages/astro)) | [`7.4.7` → `7.4.13`](https://renovatebot.com/diffs/npm/astro/7.4.7/7.4.13) | ![age](https://developer.mend.io/api/mc/badges/age/npm/astro/7.4.13?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/astro/7.4.7/7.4.13?slim=true) |
| [cap-widget](https://trycap.dev) ([source](https://github.com/tiagozip/cap)) | [`0.1.63` → `0.1.64`](https://renovatebot.com/diffs/npm/cap-widget/0.1.63/0.1.64) | ![age](https://developer.mend.io/api/mc/badges/age/npm/cap-widget/0.1.64?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/cap-widget/0.1.63/0.1.64?slim=true) |
| [capjs-core](https://github.com/tiagozip/cap) | [`0.1.16` → `0.1.20`](https://renovatebot.com/diffs/npm/capjs-core/0.1.16/0.1.20) | ![age](https://developer.mend.io/api/mc/badges/age/npm/capjs-core/0.1.20?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/capjs-core/0.1.16/0.1.20?slim=true) |
| [eslint](https://eslint.org) ([source](https://github.com/eslint/eslint)) | [`10.14.0` → `10.15.0`](https://renovatebot.com/diffs/npm/eslint/10.14.0/10.15.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/eslint/10.15.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/eslint/10.14.0/10.15.0?slim=true) |
| [eslint-plugin-perfectionist](https://perfectionist.dev) ([source](https://github.com/azat-io/eslint-plugin-perfectionist)) | [`5.13.0` → `5.14.0`](https://renovatebot.com/diffs/npm/eslint-plugin-perfectionist/5.13.0/5.14.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/eslint-plugin-perfectionist/5.14.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/eslint-plugin-perfectionist/5.13.0/5.14.0?slim=true) |
| [markdownlint-cli2](https://github.com/DavidAnson/markdownlint-cli2) | [`0.24.1` → `0.24.2`](https://renovatebot.com/diffs/npm/markdownlint-cli2/0.24.1/0.24.2) | ![age](https://developer.mend.io/api/mc/badges/age/npm/markdownlint-cli2/0.24.2?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/markdownlint-cli2/0.24.1/0.24.2?slim=true) |
| [postcss-html](https://github.com/ota-meshi/postcss-html) | [`2.0.0` → `2.0.1`](https://renovatebot.com/diffs/npm/postcss-html/2.0.0/2.0.1) | ![age](https://developer.mend.io/api/mc/badges/age/npm/postcss-html/2.0.1?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/postcss-html/2.0.0/2.0.1?slim=true) |
| [typescript-eslint](https://typescript-eslint.io/packages/typescript-eslint) ([source](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/typescript-eslint)) | [`8.72.2` → `8.74.0`](https://renovatebot.com/diffs/npm/typescript-eslint/8.72.2/8.74.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/typescript-eslint/8.74.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/typescript-eslint/8.72.2/8.74.0?slim=true) |

> ❗ **Important**
>
> Release Notes retrieval for this PR were skipped because no github.com credentials were available.
> If you are self-hosted, please see [this instruction](https://github.com/renovatebot/renovate/blob/master/docs/usage/examples/self-hosting.md#githubcom-token-for-release-notes).

---

### Configuration

📅 **Schedule**: (in timezone Europe/Stockholm)

- Branch creation
  - "before 6am on monday"
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://github.com/renovatebot/renovate/discussions) if that's undesired.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Mend Renovate](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4yODguMCIsInVwZGF0ZWRJblZlciI6IjQzLjI4OC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJ0eXBlL2Nob3JlIl19-->

Reviewed-on: #429
2026-11-27 10:59:42 +00:00
.forgejo/workflows test: end-to-end specs and a pull request gate (#382) 2026-10-13 08:07:01 +00:00
.vscode fix(renovate): disable major updates (#67) 2026-07-19 12:35:07 +00:00
docs docs: describe the keycloak setup and fix two copy facts (#422) 2026-11-15 11:05:13 +00:00
drizzle fix(withdrawal): record one open request and send one receipt (#383) 2026-10-13 08:25:46 +00:00
public fix: point security.txt at bitborg.se (#281) 2026-10-03 00:15:39 +00:00
scripts chore: remove the legacy name and guard against it (#400) 2026-10-17 21:12:16 +00:00
src docs: say the bitborg id pages are in swedish (#424) 2026-11-16 08:50:15 +00:00
.dockerignore chore: initial commit 2026-06-14 20:50:39 +02:00
.env.example chore: remove the legacy name and guard against it (#400) 2026-10-17 21:12:16 +00:00
.gitignore chore(test): replace nightwatch with playwright as the end-to-end framework (#244) 2026-09-21 10:08:09 +00:00
.markdownlint-cli2.jsonc style: adjust & apply linting (#46) 2026-07-17 07:23:55 +00:00
.prettierignore chore(lint): ignore .claude in eslint, prettier and stylelint (#356) 2026-10-11 14:14:16 +00:00
.stylelintignore chore(lint): ignore .claude in eslint, prettier and stylelint (#356) 2026-10-11 14:14:16 +00:00
astro.config.mjs chore: remove the legacy name and guard against it (#400) 2026-10-17 21:12:16 +00:00
Containerfile chore(deps): update toolchain (#417) 2026-11-15 21:44:59 +00:00
CONTRIBUTING.md docs: absorb sign-up, navigation and claims knowledge from planning docs (#278) 2026-10-02 22:17:45 +00:00
drizzle.config.ts chore: initial commit 2026-06-14 20:50:39 +02:00
eslint.config.mjs chore(lint): ignore .claude in eslint, prettier and stylelint (#356) 2026-10-11 14:14:16 +00:00
lefthook.json chore(deps): pin sort-package-json instead of pnpm dlx (#380) 2026-10-13 07:27:25 +00:00
package.json fix(deps): update non-major dependencies (#429) 2026-11-27 10:59:42 +00:00
playwright.config.ts chore(test): replace nightwatch with playwright as the end-to-end framework (#244) 2026-09-21 10:08:09 +00:00
pnpm-lock.yaml fix(deps): update non-major dependencies (#429) 2026-11-27 10:59:42 +00:00
pnpm-workspace.yaml fix(deps): pin @emnapi packages away from 2.0.0-beta.2 (#431) 2026-11-26 15:29:18 +00:00
README.md docs: describe the keycloak setup and fix two copy facts (#422) 2026-11-15 11:05:13 +00:00
renovate.json docs(renovate): record why the portal does not automerge dependency prs (#206) 2026-08-09 19:57:44 +00:00
stylelint.config.mjs chore: initial commit 2026-06-14 20:50:39 +02:00
tsconfig.json chore: keep astro check out of the coverage report (#286) 2026-10-04 12:45:50 +00:00
vitest.config.ts feat(gdpr): purge expired email-change requests and invite codes (#275) 2026-10-02 09:52:51 +00:00

bitborg-web

The public web portal for bitborg (a Swedish, self-hosted Forgejo git service). Served at https://www.bitborg.se; the Forgejo app itself lives at https://git.bitborg.se.

It provides:

  • Marketing + legal pages — landing, Terms of Service, Privacy Policy, plus the signed-in account panel, checkout and the withdrawal form. Swedish by default at /, English under /en/, with a manual language switcher. The browser's Accept-Language is not used.
  • Open sign-up — creates a participant account (a way to take part in others' projects; hosting comes with the paid account) by creating a user in Keycloak; the Forgejo account is created on first OIDC login (Forgejo's own public registration stays disabled). Gated by a self-hosted proof-of-work captcha and a SIGNUPS_OPEN kill switch (ADR 0029).
  • Transactional email — sign-up welcome, sent via Sweego's HTTP API in the recipient's language. Every message is From no-reply@email.bitborg.se (fixed in src/lib/email.ts); content lives in src/i18n/emails.ts. Set SWEEGO_API_KEY to enable; unset, the handlers degrade gracefully and send nothing.

Built with Astro (Node adapter, server output) + TypeScript + Drizzle (PostgreSQL). Deployed as a container by bitborg-infra behind Caddy.

Why Astro (not SvelteKit/Next): content-first site with a few server actions, FOSS, and not tied to a single hosting vendor. See ADR 0010 and 0011 in bitborg-docs.

Develop

Local SSL is necessary for running the local development server.

We suggest using mkcert for this.

cp .env.example .env        # fill DATABASE_URL, KEYCLOAK_*, OIDC_*
mkcert -install             # Install CA trust
mkcert localhost            # Generate certificate files
pnpm install
pnpm dev                     # https://localhost:4321

Useful scripts: pnpm check (astro/type check), pnpm build (standalone server into dist/), pnpm db:generate / pnpm db:migrate (Drizzle).

Testing

pnpm test runs the Vitest unit suite. pnpm test:e2e runs the Playwright end-to-end suite (src/test/e2e/) against a built copy of the site on chromium, webkit and mobile-safari; add E2E_FULL_MATRIX=true to also run firefox. pnpm test:e2e:ui opens Playwright's UI mode; pnpm test:e2e:report opens the last HTML report.

Layout

Path Purpose
src/pages/ sv pages at /, English under /en/; api/ server endpoints
src/layouts/Base.astro, Legal.astro shared shell; Legal wraps Markdown pages
src/i18n/ui.ts UI string dictionaries (sv/en) + useTranslations helper
src/content/{sv,en}/ long-form ToS/privacy copy (Markdown, per language)
src/lib/keycloak.ts Keycloak admin API client (user provisioning)
src/lib/email.ts, src/i18n/emails.ts Sweego email sender + localized email content (sv/en)
scripts/migrate.mjs, drizzle/ runtime migrator + generated SQL migrations
src/lib/db.ts, src/db/schema.ts Drizzle client + schema (invite_codes, signups, checkout_consents, withdrawal_requests, renewal_reminders)

Configuration

Main environment variables (see .env.example): PUBLIC_SITE_URL, PUBLIC_GIT_APP_URL, DATABASE_URL, SIGNUPS_OPEN, PAYMENTS_ENABLED, BILLING_API_URL, BILLING_API_TOKEN (billing service; an unset URL hides the withdrawal section), BILLING_SELL_COUNTRIES, CAP_SECRET, SWEEGO_API_KEY (email; blank disables sending), EMAIL_FROM_ADDRESS, OIDC_ISSUER, OIDC_CLIENT_ID, OIDC_CLIENT_SECRET, OIDC_REDIRECT_URI, PUBLIC_AUTH_URL, SESSION_SECRET, KEYCLOAK_URL, KEYCLOAK_REALM, KEYCLOAK_ADMIN_CLIENT_ID, KEYCLOAK_ADMIN_CLIENT_SECRET, SITE_NAME, HOST and PORT. Secrets are never committed; in production they come from podman secrets via bitborg-infra.