Repository navigation
New installations without Django, and image upload over /api/v1 for exact-sync - #1
Merged
maubreville merged 9 commits intoNov 17, 2026
Conversation
…ables on an empty database (crates/exact-db/bootstrap/exact_base_schema.sql, generated from a pinned EXACT commit by scripts/make-base-schema.sh); exact-cli create-superuser makes the first account The schema file is what EXACT's Django migrations create in an empty database, including django_migrations, content types, permissions and seeded set tags, so the original EXACT can still be pointed at the database later. It is applied in one transaction and only when the schema public has no tables; existing databases are migrated as before. An empty database plus `migrate` matches baseline/schema-local-20261027.json (62 tables). create-superuser takes the password from EXACT_ADMIN_PASSWORD or standard input, adds the preferences row Django's post_save signal would create and, with --team, makes the user admin of that team (created when missing). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…Windows (core.autocrlf=true) deploy/docker-entrypoint.sh got CRLF and the server container failed with "exec /app/docker-entrypoint.sh: no such file or directory" Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…o a new installation can create image sets; on the real files of an existing EXACT set IMAGE_MODE=ro (DEPLOY.md, exact.env.example); DEPLOY.md: cookie and passkey settings for a try-out without https Before, the default was read-only (made for the beta on a copy of production), and creating an image set on a new installation failed with "Read-only file system (os error 30)". The worker keeps its read-only mount. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…, MEDIA_ROOT and the cache, and refuses to start with the fix (chown on Linux, a folder of your own on Windows/macOS) instead of failing uploads later; exact.env.example explains the host folders On Docker Desktop the example's /srv/... paths do not exist on the host and were created inside Docker's VM owned by root, so every upload failed with "Permission denied" (the browser only reported a failed connection). The image store is not checked with IMAGE_MODE=ro; workers and one-off commands are not wrapped. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…opy one settings file, set two passwords, `up -d --build`; no GPU, worker opt-in, data in Docker volumes, the first admin created on first start), existing EXACT installations follow docs/from-exact.md (copy, both on the same data, Django off) - exact-cli create-superuser --if-none: nothing happens once a superuser exists; the container entrypoint uses it to create EXACT_ADMIN_USER / EXACT_ADMIN_PASSWORD (optionally EXACT_ADMIN_TEAM) on the first start, leaves restored EXACT databases alone, and refuses the example password change-me - deploy/quickstart.yml + quickstart.env.example: its own compose project (exact-rust) next to the unchanged deploy/docker-compose.yml; the image folders /data/images and /data/media exist in the image owned by `exact`, so empty named volumes are writable - docs: Installation page that asks "do you already run EXACT?", Start from scratch, Moving from EXACT; DEPLOY.md becomes the reference under it, coexistence moves under it; README, index and django-differences link to the two guides Tested on Windows/Docker Desktop: first start creates the tables, the admin and the team; a restart creates nothing; an image set created and a TIFF uploaded over the API land in the volume and get a thumbnail. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…EXACT and to Docker: the two paths (new / existing EXACT), and a new installation in six steps (Docker Desktop, Download ZIP, a terminal in the folder, the settings file created and opened with one command per system, one start command, log in), with everyday use, updates and where to look when it fails docs/quickstart.md offers the same ZIP download and editor commands. The ZIP download needs no git and keeps the repository's LF line endings on Windows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…-sync's ImagesApi.create_image does (multipart, files and image_set in any order, ZIPs unpacked, duplicates skipped; 200 with the new images as a v1 list page); was 501 exact-sync sends the file before image_set, so files are staged in the image root until the set is known and checked; staged files are removed also when the request is refused. The route has no body limit (the generic v1 handler buffers bodies); GET is the generic list, other methods answer 405 as before. The legacy and v2 uploads share the refactored streaming (stage/process) and answer as before; a ZIP reports all images it contained. Unlike Django, the caller needs the right to edit the unlocked set (docs/django-differences.md). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…HTTP Basic auth (no session, no CSRF token); the image moves with its annotation, a target without the annotation type refuses with 409; skipped when the installed exact_sync has no move_image Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
|
LGTM |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two things in one branch:
exact-cli migratecreates EXACT's own tables on an emptydatabase, and
exact-cli create-superusermakes the first account. A quickstart compose file gets a new user fromzero to a running instance with one settings file and one command.
POST /api/v1/images/images/(whatImagesApi.create_imagecalls) answered 501 and now works as it does on Django.
Existing installations next to Django are not affected:
migrateonly creates EXACT's tables when the database hasnone, and changes nothing otherwise.
New installations without Django
crates/exact-db/bootstrap/exact_base_schema.sqlis what EXACT's Django migrations create in anempty database, generated from a pinned EXACT commit by
scripts/make-base-schema.sh. That includesdjango_migrations,content types, permissions and the seeded set tags, so the original EXACT can still be pointed at the database later.
It is applied in one transaction. An empty database plus
migratematchesbaseline/schema-local-20261027.json(62 tables).exact-cli create-superusertakes the password fromEXACT_ADMIN_PASSWORDor stdin, and with--teammakes the user admin of that team. With--if-noneit does nothing once a superuser exists; the containerentrypoint uses that on first start and refuses the example password
change-me.deploy/quickstart.yml+quickstart.env.exampleis its own compose project next to the unchangeddeploy/docker-compose.yml: no GPU, worker opt-in, data in Docker volumes..gitattributeskeeps shell scripts LF; withcore.autocrlf=truethe entrypoint got CRLF and the containerfailed with
exec /app/docker-entrypoint.sh: no such file or directory.IMAGE_MODE=rw). The read-only default made creating an image setfail with "Read-only file system". Set
IMAGE_MODE=roon the real files of an existing EXACT.MEDIA_ROOTand the cache, and refusesto start with the fix, instead of every upload failing later with "Permission denied".
EXACT;
DEPLOY.mdbecomes the reference under it. README: "Get started" right after the screenshots, in six steps.Image upload over
/api/v1Django's
ImageViewSet.create: multipart with the files andimage_set, ZIPs unpacked, duplicates (same name andchecksum) skipped. The answer is 200 with the new images as a page of the v1 list.
image_set, so uploads are staged as temporary.upload-*filesin the image root until the set is known and checked. They are removed on every path, including refusals.
buffers bodies. GET is still the generic list, and PUT/PATCH/DELETE answer 405 as before.
/images/image/upload/{set}/) and v2 uploads use the same refactored streaming and answeras before. A ZIP now reports all images it contained, not only the last.
docs/django-differences.md):add_imagemodel permission.image_setis a 400; Django answers 500.Tests
tests/conformance/test_v1_image_create.py(Rust only), 6 tests:test_exact_sync.py:ImagesApi.move_image/list_move_targetsover HTTP Basic auth (no session, no CSRF token).The image moves with its annotation; a target without the annotation type refuses with 409. The test skips itself when
the installed exact-sync has no
move_image; that is on the EXACT-Sync branchfeature/move-image.docs/api.mddocuments the endpoint with an exact-sync example.How it was tested
migrate+create-superuser(Windows, Docker Desktop):exact-apiunit tests (66) pass; clippy is clean forexact-apinothing; an image set created and a TIFF uploaded over the API land in the volume and get a thumbnail.
Please run
make verify(or at leasttest_v1_image_create.py,test_v2_upload.pyandtest_exact_sync.py) beforemerging.
🤖 Generated with Claude Code