Commit Graph
14 Commits
Author SHA1 Message Date
tajniak81andClaude Opus 5.5 b9be8be156 Run docwell-db as a stock PocketBase and let the server set it up
CI / go (Server) (push) Failing after 22m50s
CI / go (Web-App) (push) Canceled after 0s
CI / frontend (push) Failing after 8m47s
CI / desktop (ubuntu-latest) (push) Successful in 2h56m50s
CI / mobile (push) Failing after 5m33s
CI / docker (push) Successful in 1h43m8s
Docs / build (push) Successful in 16m2s
Docs / deploy (push) Skipped
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
docwell-db no longer needs a Docwell image: the stack runs
tajniak81/pocketbase-docker-root as it is, and docwell-server does what
the migrations and pb_hooks used to do inside PocketBase.

On start, docwell-server now:
- waits for PocketBase and imports Docwell's collections from an
  embedded snapshot (internal/pbschema). Existing collections and
  fields are matched by name, so their data is kept; the admin-managed
  users options (OAuth2 providers, magic link) are left untouched.
- writes the DOCWELL_APP_NAME, DOCWELL_WEB_URL, DOCWELL_MAIL_FROM,
  DOCWELL_SMTP_* and DOCWELL_S3_* settings into PocketBase, as the
  boot hook did.

It also replaces the hook's two routes: token checks use PocketBase's
auth-refresh (the organization name is read as the superuser), and
Docwell's own emails go out over SMTP from the server. PocketBase never
returns the SMTP password, so the server keeps a copy in the
superuser-only instance_settings collection; a password saved before
this change has to be entered once more in the admin panel.

Database/ keeps pb_migrations as the source of the schema;
export-schema.sh regenerates the snapshot from them. Database/Dockerfile
and pb_hooks are removed, the release no longer builds docwell-db, the
AIO image runs PocketBase without migrations or hooks, and the compose
files default DB_IMAGE to the stock image and pass the settings to the
server instead of the database.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-13 20:09:38 +01:00
tajniak81andClaude Opus 5.5 ad26727521 Add production compose variants and base docwell-db on the PocketBase image
CI / go (Server) (push) Successful in 16m33s
CI / go (Web-App) (push) Successful in 12m1s
CI / frontend (push) Failing after 6m32s
CI / desktop (ubuntu-latest) (push) Failing after 21m52s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
CI / mobile (push) Failing after 5m2s
CI / docker (push) Successful in 18m56s
Docs / build (push) Successful in 10m45s
Docs / deploy (push) Skipped
Docker/ and Docker-AIO/ each get docker-compose.prod.yml plus S3,
SeaweedFS and SeaweedFS-split variants, with matching .env.prod*.example
templates and a README.

docwell-db is now built FROM tajniak81/pocketbase-docker-root, which
creates the superuser and serves PocketBase on 8090; data moves to
/pb/pb_data. The boot hook applies DOCWELL_S3_* settings when set.
The AIO start script accepts PB_ENCRYPTION_KEY. The base image is
amd64-only, so the docwell-db release builds amd64 only for now.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-12 11:39:01 +01:00
tajniak81andClaude Opus 5.5 972a022f7e Pin flutter-action to a release that runs on node20
CI / go (Server) (push) Successful in 13m23s
CI / go (Web-App) (push) Successful in 9m58s
CI / frontend (push) Successful in 11m18s
CI / desktop (ubuntu-latest) (push) Successful in 34m25s
CI / mobile (push) Successful in 5m5s
CI / docker (push) Successful in 4m43s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
Release / images (., Docker-AIO/Dockerfile, docwell) (push) Successful in 1h8m29s
Release / images (., Server/Dockerfile, docwell-server) (push) Successful in 35m44s
Release / images (., Web-App/Dockerfile, docwell-web) (push) Successful in 31m31s
Release / images (Database, Database/Dockerfile, docwell-db) (push) Successful in 21m6s
Release / desktop (Desktop-App/bin/*.deb Desktop-App/bin/*.rpm Desktop-App/bin/*.AppImage , linux, ubuntu-latest, linux:create:deb linux:create:rpm linux:create:appimage) (push) Successful in 49m14s
Release / desktop (Desktop-App/bin/*-installer.exe, windows, windows-latest, windows:package) (push) Canceled after 0s
Release / release (push) Canceled after 0s
flutter-action 2.22 moved to actions/cache@v5, a node24 action the
Gitea runners reject, so the mobile job never set up Flutter. 2.21.0 is
the last release on actions/cache@v4.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 18:59:42 +01:00
tajniak81andClaude Opus 5.5 0aa79b7530 Use artifact actions that run on Gitea
CI / go (Server) (push) Successful in 12m44s
CI / go (Web-App) (push) Successful in 10m14s
CI / frontend (push) Successful in 11m15s
CI / desktop (ubuntu-latest) (push) Successful in 33m54s
CI / mobile (push) Failing after 26s
CI / docker (push) Successful in 4m0s
Docs / build (push) Successful in 10m21s
Docs / deploy (push) Skipped
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
Release / desktop (Desktop-App/bin/*-installer.exe, windows, windows-latest, windows:package) (push) Canceled after 0s
Release / release (push) Canceled after 0s
Release / images (., Docker-AIO/Dockerfile, docwell) (push) Failing after 26s
Release / images (., Server/Dockerfile, docwell-server) (push) Failing after 29s
Release / images (., Web-App/Dockerfile, docwell-web) (push) Failing after 28s
Release / images (Database, Database/Dockerfile, docwell-db) (push) Failing after 22s
Release / desktop (Desktop-App/bin/*.deb Desktop-App/bin/*.rpm Desktop-App/bin/*.AppImage , linux, ubuntu-latest, linux:create:deb linux:create:rpm linux:create:appimage) (push) Successful in 27m3s
Version 4 of upload-artifact and download-artifact stops on any server
other than github.com, so the release moves the desktop installers
between jobs with v3, which Gitea supports. v3 downloads every artifact
into its own folder, so the release step attaches dist/*/*.

The docs workflow only uploads and deploys on GitHub, where Pages
exists; on Gitea it checks that the site builds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 11:37:40 +01:00
tajniak81andClaude Opus 5.5 75fed90b71 Smoke-test the compose stack over its own network in CI
CI / go (Server) (push) Successful in 13m3s
CI / go (Web-App) (push) Successful in 10m9s
CI / frontend (push) Successful in 10m57s
CI / desktop (ubuntu-latest) (push) Successful in 45m11s
CI / mobile (push) Failing after 38s
CI / docker (push) Successful in 4m54s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
On Gitea the job runs in a container that drives the host's Docker, so
the stack's published ports are not on the job's localhost. The checks
now run from a curl container on the docwell_default network, and the
stack is taken down even when a check fails.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 11:30:21 +01:00
tajniak81andClaude Opus 5.5 6d7fc7043e Install the GTK 4 webview stack for desktop builds
Release / images (., Docker-AIO/Dockerfile, docwell) (push) Failing after 21s
Release / images (., Server/Dockerfile, docwell-server) (push) Failing after 32s
Release / images (., Web-App/Dockerfile, docwell-web) (push) Failing after 38s
Release / images (Database, Database/Dockerfile, docwell-db) (push) Failing after 40s
Release / desktop (Desktop-App/bin/*.deb Desktop-App/bin/*.rpm Desktop-App/bin/*.AppImage , linux, ubuntu-latest, linux:create:deb linux:create:rpm linux:create:appimage) (push) Failing after 31m2s
CI / go (Server) (push) Successful in 13m49s
CI / go (Web-App) (push) Successful in 10m7s
CI / frontend (push) Successful in 11m17s
CI / desktop (ubuntu-latest) (push) Successful in 41m19s
CI / mobile (push) Failing after 28s
CI / docker (push) Failing after 3m32s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
Release / desktop (Desktop-App/bin/*-installer.exe, windows, windows-latest, windows:package) (push) Canceled after 0s
Release / release (push) Canceled after 0s
Wails 3.0 builds against GTK 4 and WebKitGTK 6.0 unless built with the
gtk3 tag, and the packages already depend on that stack, so CI and the
release install libgtk-4-dev and libwebkitgtk-6.0-dev in place of the
GTK 3 ones.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 11:06:44 +01:00
tajniak81andClaude Opus 5.5 d01c61df20 Install Rust in CI before building yrs.wasm
CI / go (Server) (push) Successful in 13m23s
CI / go (Web-App) (push) Successful in 10m48s
CI / frontend (push) Failing after 6m41s
CI / desktop (ubuntu-latest) (push) Failing after 31m25s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
CI / mobile (push) Failing after 37s
CI / docker (push) Failing after 2m44s
The Gitea runner image has no rustup, so the Server job failed before
go generate. dtolnay/rust-toolchain installs stable with the
wasm32-wasip1 target.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 10:36:05 +01:00
tajniak81andClaude Opus 5.5 be13a5ab6f Pin workflow actions to versions that run on node20
CI / go (Server) (push) Failing after 1m25s
CI / go (Web-App) (push) Canceled after 0s
CI / frontend (push) Failing after 7m19s
CI / desktop (ubuntu-latest) (push) Failing after 22m58s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
CI / mobile (push) Failing after 4m57s
CI / docker (push) Failing after 18m11s
Docs / build (push) Failing after 6m33s
Docs / deploy (push) Skipped
Release / images (., Docker-AIO/Dockerfile, docwell) (push) Failing after 2m58s
Release / images (., Server/Dockerfile, docwell-server) (push) Failing after 28s
Release / images (., Web-App/Dockerfile, docwell-web) (push) Failing after 24s
Release / images (Database, Database/Dockerfile, docwell-db) (push) Failing after 28s
Release / desktop (Desktop-App/bin/*.deb Desktop-App/bin/*.rpm Desktop-App/bin/*.AppImage , linux, ubuntu-latest, linux:create:deb linux:create:rpm linux:create:appimage) (push) Failing after 33m49s
Release / desktop (Desktop-App/bin/*-installer.exe, windows, windows-latest, windows:package) (push) Canceled after 0s
Release / release (push) Canceled after 0s
The Gitea runners reject actions that declare node24, so every job
stopped at setup. checkout, setup-go and setup-node go back to their
node20 releases (v4, v5, v4); the Node used for builds is still 24.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 10:34:05 +01:00
tajniak81andClaude Opus 5.5 154fed2a06 Run the release workflow on Gitea
CI / go (Server) (push) Failing after 22s
CI / go (Web-App) (push) Canceled after 0s
CI / frontend (push) Failing after 26s
CI / desktop (ubuntu-latest) (push) Failing after 23s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
CI / mobile (push) Failing after 19s
CI / docker (push) Failing after 26s
Docs / build (push) Failing after 29s
Docs / deploy (push) Skipped
Release / images (., Docker-AIO/Dockerfile, docwell) (push) Failing after 20s
Release / images (., Server/Dockerfile, docwell-server) (push) Failing after 31s
Release / images (., Web-App/Dockerfile, docwell-web) (push) Failing after 28s
Release / images (Database, Database/Dockerfile, docwell-db) (push) Failing after 18s
Release / desktop (Desktop-App/bin/*.deb Desktop-App/bin/*.rpm Desktop-App/bin/*.AppImage , linux, ubuntu-latest, linux:create:deb linux:create:rpm linux:create:appimage) (push) Failing after 14s
Release / desktop (Desktop-App/bin/*-installer.exe, windows, windows-latest, windows:package) (push) Canceled after 0s
Release / release (push) Canceled after 0s
- Images go to the registry of the Gitea that runs the workflow (or the
  REGISTRY variable), signed in with the REGISTRY_TOKEN secret. A plain
  http Gitea gets a plain http registry in BuildKit's config, and the
  credentials are written straight into the client config, since docker
  login refuses such registries.
- The build cache is kept in the registry, not the GitHub Actions cache.
- One release job creates the Gitea release through its API once every
  build has passed, and attaches the Windows and Linux installers.
- macOS is left out: Gitea has no hosted Mac runners, so the DMG is
  built by hand. The docs link comes from the DOCS_URL variable instead
  of a github.io address.
- AppImages are built without FUSE, which runner containers lack.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 15:49:22 +01:00
tajniak81andClaude Opus 5.5 40d515d15b Add toggles, embeds, link cards, block links, archive, version diff, space export and desktop 1.0
Editor:
- Toggles (Tiptap Details). Open state is per reader, not saved.
- Embeds for YouTube, Vimeo, Loom, Figma, CodePen, Spotify, Google Docs
  and Maps, in sandboxed frames. Other addresses become link cards.
- Link cards with title, description and picture read by docwell-server
  (GET /link-preview). The fetcher refuses private, loopback, link-local
  and CGNAT addresses after DNS resolution, redirects included.
- Block links: a margin button gives a block a short id and copies
  /p/<id>#b-<block>. Opening one jumps to the block and flashes it.
- Markdown, HTML and PDF exports handle the new blocks; HTML import reads
  <details> as a toggle.

Pages and spaces:
- History gets a Changes view: block and word diff against the previous
  version or the page as it is now.
- Archive: archived pages leave the tree and become read-only but stay
  readable; a space's Archive lists them with Unarchive. New migration
  (pages.archived_at) and page.archived / page.unarchived webhook events.
- Full space export (GET /spaces/{id}/export): a zip of Markdown or HTML
  files with subpages in folders, an index, and attachments under _files/.
  Links between exported pages and to attachments become relative paths.

Desktop 1.0:
- Several servers, each with its own sign-in; old settings files carry over.
- Session tokens in the system keychain (go-keyring), moved out of
  localStorage on first start.
- Native menu bar (File, Edit, View, Window, Help) with a Server submenu.
- docwell:// links may point at a block.
- Release workflow builds Windows NSIS, macOS DMG and Linux deb, rpm and
  AppImage installers and attaches them to the release;
  build/set-version.mjs stamps the version into their metadata.

Not yet run: the release workflow, the desktop menus by eye, and macOS or
Linux builds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-01 14:14:14 +01:00
tajniak81andClaude Opus 5.5 dbe49b892f Add multi-arch release images and a documentation site
CI / go (Server) (push) Canceled after 0s
CI / go (Web-App) (push) Canceled after 0s
CI / frontend (push) Canceled after 0s
CI / desktop (macos-latest) (push) Canceled after 0s
CI / desktop (ubuntu-latest) (push) Canceled after 0s
CI / desktop (windows-latest) (push) Canceled after 0s
CI / mobile (push) Canceled after 0s
CI / docker (push) Canceled after 0s
Docs / build (push) Canceled after 0s
Docs / deploy (push) Canceled after 0s
Release / images (., Docker-AIO/Dockerfile, docwell) (push) Canceled after 0s
Release / images (., Server/Dockerfile, docwell-server) (push) Canceled after 0s
Release / images (., Web-App/Dockerfile, docwell-web) (push) Canceled after 0s
Release / images (Database, Database/Dockerfile, docwell-db) (push) Canceled after 0s
Release: pushing a v* tag builds docwell-db, docwell-server, docwell-web
and the all-in-one image for linux/amd64 and linux/arm64 and pushes
them to GHCR, tagged with the version and latest. The build stages run
on the build machine's platform and Go cross-compiles, so arm64 needs no
emulation except for the final apk step (checked by building the server
image for arm64). The compose files name the released images, so
`docker compose up -d` runs a release and `--build` still builds the
checkout; DOCWELL_REGISTRY and DOCWELL_VERSION pick them.

Docs: Docs-Site is a VitePress site with a quick start, every
configuration variable, reverse-proxy setups, backups and upgrades, a
user guide, people and access, the admin panel and the API. CI builds
it, and the Docs workflow publishes it to GitHub Pages. It lives outside
docs/, which stays local planning material.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 17:45:16 +01:00
tajniak81andClaude Opus 5.5 ba394b8fac Finish Phase 0: lint, codegen, contributor docs and the two remaining spikes
Repository basics:
- CONTRIBUTING.md and CODE_OF_CONDUCT.md (Contributor Covenant 2.1)
- SPDX AGPL-3.0-or-later headers on all hand-written sources, checked in CI
- golangci-lint (shared .golangci.yml), ESLint and Prettier, all run in CI

API codegen from api/openapi.yaml (npm run generate, drift fails CI):
- Go types via oapi-codegen in Server/internal/api
- a contract test that the router and the spec list the same routes
- Dart models via Phone-App/tool/generate_api.dart; the app uses them

Spike: shared Tiptap editor in a Flutter WebView (ADR-4)
- @docwell/editor-bridge builds the editor into one HTML page with a
  versioned JSON protocol; Phone-App hosts it with webview_flutter and a
  native toolbar. Integration test passes on an Android API 35 emulator.
- flutter_inappwebview dropped: its Android plugin fails on AGP 9.

Spike: Wails v3 desktop (ADR-11)
- system tray, docwell:// deep links (page and space only) with
  single-instance hand-off, and the built-in updater with a required
  ed25519 signing key. Verified on Windows.
- regenerated build assets register the scheme and drop template
  placeholders.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 16:11:07 +01:00
tajniak81andClaude Opus 5.5 5e1dcf4291 Add real-time collaboration with page history
Pages are now shared Yjs documents. docwell-server relays the y-websocket
protocol at /collab (token sent as the first message), flushes updates to
page_yupdates every second, and compacts them into page_ydoc with yrs
compiled to WebAssembly under wazero (ADR-3) after 30 s idle or when the
last editor leaves. Compaction refreshes content_json/content_text and
records page_versions; versions can be listed, previewed and restored.

The editor connects through a small y-protocols provider with carets and
presence. Pages saved before this change are seeded from content_json.
The yrs module lives in Server/ycrdt-wasm and is built by go generate,
CI and the Dockerfiles rather than committed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 11:52:55 +01:00
tajniak81andClaude Opus 5.5 4903bb12dd Scaffold Docwell monorepo with PocketBase authentication
Phase 0 foundation for Docwell, an open-source knowledge base:

- Database: PocketBase v0.40.6 with initial schema migrations; users is
  the built-in auth collection, plus a hook for token checks and
  env-driven app URL/SMTP settings
- Server: Go API (health, version, auth endpoints forwarded to
  PocketBase, admin user list) with an embedded Vue admin panel
- Web-App: Go static server and Vue/Tailwind app with Tiptap editor,
  sign-in, sign-up, password reset and email verification (EN/PL)
- Desktop-App: Wails v3 host reusing the web app
- Phone-App: Flutter app with sign-in
- Shared packages (editor, ui, api-client), OpenAPI spec, Docker
  compose (separate services and all-in-one), GitHub Actions CI
- Docs: feature inventory and architecture/build plan

Licensed under AGPL-3.0-or-later.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-30 22:18:25 +01:00