Rust-only server, multi-arch Docker image, CI and docs #2

Merged
wt merged 5 commits from develop into main 2026-10-30 09:35:03 +00:00
Owner

Summary

  • Go-сервер удалён, остался только Rust. Исходники Go сохранены в теге v1.0.0. Поведение Go остаётся эталоном API: его ответы записаны в tools/compatibility_expected.txt, и tools/compatibility.py сверяет с ними Rust (--update перезаписывает эталон после намеренного изменения). Исходная SQLite-схема Go зафиксирована в tests/fixtures/go_schema_v1.sql.
  • Веб-клиент перенесён из internal/httpapi/web/ в web/.
  • Мультиплатформенный Docker-образ linux/amd64, linux/arm64, linux/arm/v7 под одним тегом. Rust кросс-компилируется нативно, под QEMU выполняется только финальный слой.
  • Docker publish: адрес registry, владелец и пользователь берутся из репозитория автоматически, имя образа приводится к нижнему регистру, базовые образы Docker Hub тянутся через зеркало (DOCKERHUB_MIRROR, по умолчанию mirror.gcr.io).
  • CI: удалена Go-задача; остались проверки Rust и сверка с эталоном.
  • Документация: README (с обложкой), AGENTS.md, ARCHITECTURE, DATA_MODEL, DEVELOPMENT, DEPLOYMENT; добавлены обложка и аватар репозитория в docs/.

Совместимость с клиентами

HTTP/JSON API, схема SQLite, формат JWT, refresh-сессии и курсоры синхронизации не изменились: Rust совпадает с записанными ответами Go на всех сценариях.

Test plan

  • cargo fmt --check, cargo test --locked (41 тест), cargo clippy -D warnings, release build
  • python3 tools/compatibility.py — совпадает с эталоном; эталон стабилен на Go и падает при изменении
  • CI на develop (run 807) — success
  • Публикация мультиплатформенного образа по тегу v1.0.0 (run 805) — success

🤖 Generated with Claude Code

## Summary - **Go-сервер удалён, остался только Rust.** Исходники Go сохранены в теге `v1.0.0`. Поведение Go остаётся эталоном API: его ответы записаны в `tools/compatibility_expected.txt`, и `tools/compatibility.py` сверяет с ними Rust (`--update` перезаписывает эталон после намеренного изменения). Исходная SQLite-схема Go зафиксирована в `tests/fixtures/go_schema_v1.sql`. - **Веб-клиент перенесён** из `internal/httpapi/web/` в `web/`. - **Мультиплатформенный Docker-образ** `linux/amd64`, `linux/arm64`, `linux/arm/v7` под одним тегом. Rust кросс-компилируется нативно, под QEMU выполняется только финальный слой. - **Docker publish:** адрес registry, владелец и пользователь берутся из репозитория автоматически, имя образа приводится к нижнему регистру, базовые образы Docker Hub тянутся через зеркало (`DOCKERHUB_MIRROR`, по умолчанию `mirror.gcr.io`). - **CI:** удалена Go-задача; остались проверки Rust и сверка с эталоном. - **Документация:** README (с обложкой), AGENTS.md, ARCHITECTURE, DATA_MODEL, DEVELOPMENT, DEPLOYMENT; добавлены обложка и аватар репозитория в `docs/`. ## Совместимость с клиентами HTTP/JSON API, схема SQLite, формат JWT, refresh-сессии и курсоры синхронизации не изменились: Rust совпадает с записанными ответами Go на всех сценариях. ## Test plan - [x] `cargo fmt --check`, `cargo test --locked` (41 тест), `cargo clippy -D warnings`, release build - [x] `python3 tools/compatibility.py` — совпадает с эталоном; эталон стабилен на Go и падает при изменении - [x] CI на `develop` (run 807) — success - [x] Публикация мультиплатформенного образа по тегу `v1.0.0` (run 805) — success 🤖 Generated with [Claude Code](https://claude.com/claude-code)
wt added 5 commits 2026-10-30 09:31:55 +00:00
ci: derive registry host, owner and user for Docker publish
CI / Go (test / vet / build) (push) Successful in 27s
CI / Rust (fmt / clippy / test / build) (push) Successful in 53s
CI / Go ↔ Rust differential + SQLite takeover (push) Successful in 1m53s
Docker publish / Build and push image (push) Failing after 1m2s
d4619ec5ba
Login failed with "Username required" because REGISTRY_OWNER was not set.
Default the registry host to this Gitea instance, the owner to the
repository owner and the user to the tag pusher, lowercase the image
name, and keep a failed GHA cache export from failing the build.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ci: pull Docker Hub base images through a mirror in Docker publish
CI / Go (test / vet / build) (push) Successful in 41s
CI / Rust (fmt / clippy / test / build) (push) Successful in 56s
CI / Go ↔ Rust differential + SQLite takeover (push) Successful in 1m37s
Docker publish / Build and push image (push) Successful in 24m18s
7bdf7b79d3
BuildKit's docker-container driver ignores the host daemon's
registry-mirrors, and the runner timed out reaching auth.docker.io.
Configure a docker.io mirror (DOCKERHUB_MIRROR, default mirror.gcr.io).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
build: publish multi-platform image (amd64, arm64, arm/v7)
CI / Go (test / vet / build) (push) Successful in 27s
CI / Rust (fmt / clippy / test / build) (push) Successful in 1m5s
CI / Go ↔ Rust differential + SQLite takeover (push) Successful in 1m38s
Docker publish / Build and push image (push) Successful in 1h6m5s
ae49c8f8c3
The builder stage runs on the build platform and cross-compiles Rust,
with GCC cross compilers for bundled SQLite, so only the small runtime
stage runs under QEMU. The workflow sets up QEMU via the Docker Hub
mirror and pushes all three platforms under the same tags.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs: add repository cover and avatar images
CI / Go (test / vet / build) (push) Successful in 39s
CI / Rust (fmt / clippy / test / build) (push) Successful in 54s
CI / Go ↔ Rust differential + SQLite takeover (push) Successful in 1m55s
16dd2a3b3c
Add a 1280x640 cover shown at the top of the README, a square variant and
a text-free repository avatar that stays legible at small sizes. SVG
sources are kept next to the rendered PNGs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Remove the Go reference server; keep only Rust
CI / Rust (fmt / clippy / test / build) (push) Successful in 1m41s
CI / HTTP/JSON reference + SQLite persistence (push) Successful in 1m16s
CI / Rust (fmt / clippy / test / build) (pull_request) Successful in 47s
CI / HTTP/JSON reference + SQLite persistence (pull_request) Successful in 1m34s
10272f3851
The Go implementation is preserved in the v1.0.0 tag. Its observable
behaviour stays the API reference: responses recorded from the Go server
live in tools/compatibility_expected.txt, and tools/compatibility.py now
compares the Rust server against them (--update re-records after an
intentional change). The Go SQLite schema is frozen in
tests/fixtures/go_schema_v1.sql for the existing-database test.

Move the web client from internal/httpapi/web to web/, drop the Go CI job
and Go version pin, and update README, AGENTS.md and docs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
wt merged commit f97cdf0f2e into main 2026-10-30 09:35:03 +00:00
Sign in to join this conversation.