Eloverblik

Dokumentation · Arkitektur og beslutninger

The stack (phase 1, epic B02)

Behaviour of what deploy/ starts. The specification is docs/architecture/phase-1.md §1.2, §1.3 and §12.1.

Commands

CommandWhat it does
make upBuilds the web app. Then, before anything else and before its cleanup is armed, takes the lock of one make up at a time (an flock on the state directory, or on its nearest directory that exists before the first make up, held until the recipe's shell is gone: elo_devtools.up_guard, B19f) and refuses a COMPOSE_PROJECT_NAME that .env sets and the environment does not; a second make up beside a running one ends at once with "another make up is running" and touches nothing, not even the other's ticket. Then stops a running worker of the project (gracefully, by its fixed container name and only where its Compose project label is the project's, as below; it waits up to the worker's grace period of 150 s for the job it runs, and a declaration job asleep in its wait gives the wait up within seconds and goes back to the queue with every attempt it had, B19f) before the start ticket is written (B19: that stop after the ticket made the first make up over a busy worker fail on the ticket's 120 s); where Docker cannot be asked at all (Colima not started), it says so and stops. Revokes a start ticket an earlier launch left unused (the next section). Refuses to run as root (UID 0). Makes data/state/ and data/state/egress/ mode 0700 if they are missing, runs the host half of the state directory's start check, pulls the images Compose does not build where they are missing and builds the others, runs the mount check, then the host half again and publishes the worker's start ticket (python -m elo_devtools.state_dir up; the next section), then removes the stopped worker and starts the stack under the Compose project elo with --no-build --pull never (nothing slow after the ticket: what is left is the migration step and the worker's own start); waits until every service is healthy (the worker: once it has claimed its ticket). When it ends, in every outcome, an interrupt, a termination, a hangup (a closed terminal) or a quit included (a second signal too: the cleanup ignores all four until the revocation is done), it revokes the ticket again where one is left (python -m elo_devtools.state_dir revoke), and fails, saying so, where that revocation cannot remove it or cannot reach the state directory. Only SIGKILL of the recipe or a power loss skips that last revocation; neither can be caught, and a ticket then lives at most its 120 seconds. A refusal stops it before any container of the stack starts, with the message, and then stops the worker by its fixed container name with docker stop (a paused one too), without asking Compose, and says which: it is stopped, none was running, or it could not be stopped and make down is to be run: a secret is not left in use in a directory just judged unsafe; make down stops the rest. The name is that of the project COMPOSE_PROJECT_NAME of the environment names, else elo, and a container of that name is stopped only where its Compose project label is that project; a container of the name that is not (a plain one, another project's) is not stopped, and the message is "could not tell which worker: run make down". A refused make up of another Compose project stops that project's worker, not this one's. It is the only supported start of the worker. Reads the owner's git-ignored .env if it exists (that is where ELOVERBLIK_REFRESH_TOKEN is). Reached at http://elo.localhost:8080
make downRevokes an unused start ticket, then stops the stack. The database volume elo_pgdata stays
make purgeThe owner's retention control (§12.1). Revokes an unused start ticket first. Asks for a confirmation (type purge; anything else, or no input, does nothing and exits 1), stops the stack, giving the worker up to 150 s, and deletes the database volume of the project (elo_pgdata) with docker compose down --volumes. It deletes nothing else: not data/ (state, capture), not .env, no other volume
make statusWhat the ingestion did and will do (§6.5, B09): counts, dates and codes from the database, read inside the running worker; never says all is well over a part it could not look at (exit 0 nothing to act on, 3 something, 1 a part not looked at). docs/daily-run.md
make demomake up and make demo-load with DEMO=1: the generated organisation and the frozen factor extract in a stack that makes no call to Energi Data Service or Eloverblik (no .env, no token, ELO_DEMO=1), under the Compose project elo-demo and the state directory data/state-demo unless the environment names others. docs/daily-run.md
make demo-loadB16a's loader, adopted: the generated organisation and the factor extract into the running stack's database; refuses a database that holds the owner's data
make stack-checkStarts a throwaway stack (project elo-check, a free port, a sentinel in place of the token, no .env), checks it against the running containers, and removes it with its volume. CI runs it
make release VERSION=X.Y.Z [ARCH=amd64|arm64]A release (B100, docs/architecture/packaging-and-setup.md §2.1 to §2.3): in a clean checkout of the tag vX.Y.Z it builds the four images, tests what each holds, saves the image files, runs the stack check in its release mode against the loaded files and writes the folder release/elo-X.Y.Z/. It pushes nothing and makes no tag. See "A release" below
make testStarts a disposable PostgreSQL 18 (deploy/testdb.sh; CI provides a service container through ELO_TEST_DATABASE_URL) and runs pytest. Without a database the database tests fail, they are not skipped (ELO_REQUIRE_DB=1)
make test-python, make test-webThe two halves of make test. make test-python SHARD=<i>/<n> runs the i-th of n parts of the Python suite, by whole test files: the parts are disjoint and together the whole suite (tools/src/elo_devtools/shard.py). CI runs four parts in parallel jobs beside the static checks, the web tests and the stack check; its last job, check, is green only when every other job succeeded

ELO_PORT (default 8080) moves the published port and the Host values with it, e.g. ELO_PORT=8081 make up is reached at http://elo.localhost:8081. To run beside another stack, also set COMPOSE_PROJECT_NAME in the environment: a project name set only in .env is not supported for the stop of a refused make up (the tool cannot read .env and does not parse it): the recipe then looks for the worker of the environment's project (or elo), not the one .env names, and where a container of that name is not of that project it stops nothing and says "could not tell which worker: run make down" (and ELO_STATE_DIR, or the two workers share one state directory). In phase 1 ELO_STATE_DIR is an absolute path inside the repository without a . or .. component; anything else is refused before anything is made. Set it in the environment, not in .env: make up resolves the state directory once (ELO_STATE_DIR of the environment, or data/state), checks that one, prints it in its export line, and hands exactly that to Compose: the environment wins over --env-file .env, so Compose mounts exactly that directory. .env is not parsed by the tool: before anything is made it asks Compose (docker compose … config, the Makefile's files with .env, without that export, the token blanked in the call's environment, the answer read in memory) which directory it would mount; where that is another, make up refuses and names only the directory it resolved and checked (".env makes Compose mount another state directory than the one make up resolved and checks (…); Compose's value is not shown (the file holds the token): remove ELO_STATE_DIR from .env or set it in the environment"): nothing Compose resolved is shown, logged or put in a message, since a slip in .env can make the token's line part of it; and where Compose cannot read the configuration it refuses, saying so. make down, make purge and the revocation resolve it the same way. The same holds for every other recipe that runs Compose with .env (B02bx-01): make down stops with the token blanked and Compose's output hidden (a failure is said in words, the revocation's status kept); verify, withdraw-day, set-price-area, unset-price-area, load-capture, refetch, probe-window, status and demo-load first ask Compose, its answer hidden, whether it can read the configuration, and stop with a message of their own when it cannot, or when it wrote anything on standard error (a warning about an unset variable names what follows a $ in the token's line; B06bv5-05, B06bv5a-25), as make up's question does; purge does not read .env. A bind mount whose source path is wrong shows that path in Docker's error at compose run: a path from ELO_STATE_DIR or CAPTURE=, never a line of .env holding the token (the token is no mount), so it needs no hiding. A .env that names $ELOVERBLIK_REFRESH_TOKEN (the variable itself, not a value) makes Compose print that name in a warning, never a value: the question is asked with the variable blank, so it passes, and the next Compose call warns by name (B06bv6a-25). The tests of the committed defaults ignore these three variables in the caller's environment, so a builder may keep them set.

Services

postgres (18.7) · migrate (one-shot: bootstraps the roles, applies the migrations) · api · worker · caddy. Only Caddy publishes a port: 127.0.0.1:${ELO_PORT:-8080}. No service uses env_file.

The worker is a singleton, for the egress ownership of §5.2 (B05 implements it): its container_name is fixed (elo-worker; <project>-worker when COMPOSE_PROJECT_NAME is set, so that throwaway stacks do not collide with elo), so a second one cannot be started; its stop_grace_period is 150 s, longer than a read timeout; and it alone mounts the host's data/state/ at /data/state (ELO_STATE_DIR moves the host side). **One worker is also held by the database** (B101, docs/architecture/packaging-and-setup.md §2.4), in both installs: see "One worker, by the lock elo.worker" below.

The state directory is private (N9). The worker runs as the host user's UID and GID (user: "${ELO_UID:?}:${ELO_GID:?}", no default, so docker compose up without them starts nothing; make up sets them and every other make target exports them), so that the worker and the capture tool are one user and the directory needs no permission for anyone else: data/state/ and everything under it is that user's; new directories are 0700, token files 0600, and an accepted existing directory has no group or other write bit and no ACL. The image has no passwd entry for that UID: HOME=/tmp, nothing asks for the user's name, the root file system is read-only and /data/state and /tmp (a tmpfs) are the only writable paths. Both modes, and make up for the worker, refuse to start when the directory or a path component above it up to the repository root is a symbolic link, is not the current user's, is writable by group or others, or has an ACL entry (macOS ACLs, Linux POSIX ACLs), or where a regular file under the state directory has more than one link (B101, in both installs: a second name of a file is a way to it that nothing judges); the message names the path, the fault and the mode. The check walks from the repository root down by descriptors (each component opened relative to its verified parent, no link followed) and hands the verified descriptors of the state directory and egress/ to the egress, the token file and the pace store, which write relative to them and judge the directory again on its descriptor before each write: what was checked is what is used.

make up runs that check on the host, then a mount check in a one-shot container of the worker's image (probe files .mount-probe-*, removed afterwards): a 0600 file made on the host is read in the container, a 0600 file made in the container is the host user's with mode 0600 on the host, the directory's permission bits read the same in both. A second container as another UID then tries to read the host's file: denied is ELO_STATE_MOUNT=enforcing (Linux; the worker's half in the container compares the owner too), read is passthrough (macOS under Colima, virtiofs: the mount reports no dependable owner, so the owner is the host half's alone). make up prints which kind it found. Probe files are removed only where this run made them: the host's while the entry is the file it holds open, the container's by the run's random nonce in it, held open until its removal; a colliding name is refused and left alone. Measurements and the reasons are in docs/build/B02b-report.md.

The launch contract. The supported start of the worker of the repository install is make up, nothing else, and an authorization belongs to one launch. Of the packaged install (docs/architecture/packaging-and-setup.md §2.3) it is docker compose up -d, and a restart is a start: there is no ticket (below, "The packaged install's worker"). make up begins by revoking: it removes start-ticket, and claims and unfinished tickets (start-ticket.*), each a regular file in the configured state directory verified by its descriptor, reached by descriptors without following a link; only then does an entry of those names that is not a regular file refuse, named and never removed. Only a state directory (or a component above it) that does not exist is nothing to revoke: where a component is a symbolic link (never followed to revoke "the other side"), is not a directory or cannot be opened, or the directory cannot be listed, the revocation fails and says that an authorization may remain, and make up refuses without writing a new ticket. This happens before the checks, so a host attempt that then refuses leaves no authorization unreported; it is the one change a refused make up may make. The revocation reports what happened: an entry already gone counts as revoked; one it could not remove, one replaced meanwhile or one still there is named, the command fails and says that an authorization may remain and make up must be run again (where the state directory cannot be reached, that its owner repairs the path, then make up: running it again would refuse again), and it never says "revoked" for it. When storage refuses the removal, the ticket lives until its 120 seconds are over. After the image build and the mount check, make up runs the host half once more and, if it passes, publishes a start ticket atomically: a file of a temporary name, 0600, made exclusively, holding a random nonce, the measured mount kind and the UTC time (nothing secret), synced, then renamed to start-ticket; a failure before the rename removes the temporary file and publishes nothing, a failure of the directory's sync after it revokes. The worker, at every start and in both kinds of mount, checks its mount, then claims the ticket: it renames start-ticket to a fresh random name (start-ticket.claim-…) relative to its verified descriptor. Of two starts that claim the same ticket exactly one wins; the other finds none and refuses. The winner refuses while the state directory holds any other entry of those names (a claim or an unfinished ticket left behind, or a directory): what can block the host's revocation blocks the worker too, and the ticket is used up where the leftover is a regular file or a directory. A link, a FIFO or another kind of entry is refused by the check of the directory before the claim, and the ticket then stays until it is revoked or 120 seconds old. It then verifies the claimed file by its descriptor (no link followed, a regular file with one link, 0600, the user's where the mount compares owners, no ACL), its age (at most **120 seconds**), its mount kind against ELO_STATE_MOUNT and its form, and removes its claim in every outcome, a refusal included, where the entry is still the file it holds open; a claim a crashed worker left is never read as a ticket. Only then is it healthy, so compose up --wait returns after the claim, and the recipe's revocation after it — which runs in every outcome, through a shell trap on exit, hangup, interrupt, quit and termination, and ignores those four signals until it is done — finds nothing on success and removes the leftover of a failed or interrupted start. SIGKILL and power loss cannot be caught and end the recipe without it; the ticket then lives at most its 120 seconds. make down and make purge revoke as well; where the revocation fails they still stop the stack (or purge) and then fail, with its message. A docker compose restart worker, a docker start, a second start, or a plain docker compose up with ELO_UID, ELO_GID and ELO_STATE_MOUNT set by hand therefore refuses, with a message that says to start with make up. The worker of the repository install has no restart policy; the packaged install's has unless-stopped. ELO_STATE_MOUNT tells the worker which checks it can make; it is not evidence that the host half ran. The 120 seconds hold an honest start: on this Mac the worker started 13 s after the ticket with a fresh database volume and 5 s after it with a warm one (images built); a compose up --wait that takes longer to start the worker refuses, which is the safe side, and make up again starts it.

The packaged install's worker: the kind volume (B101)

With ELO_STATE_MOUNT=volume the state is the named volume elo_state, no path of the host holds it, and the worker judges it alone, at every start, before any lock, file or call: every directory at and under /data/state is 0700 and every file 0600, the worker's user's, a regular file has one link, no link is followed, and tokens/ is looked at whether or not a token is configured; it refuses with the path and the fault. No ticket is asked. The worker also reads its own mount table and refuses a /data/state whose mount is not a named volume of Docker's local driver (the mount's root is …/volumes/<name>/_data; a bind of a host path has the host path, or virtiofs on a Mac). The image runs as its own user, UID and GID 10001, and holds /data/state as that user's, 0700; an empty named volume takes that owner and mode over at its first mount (measured on Linux, in Colima's VM, by B101: root:root 0755 after docker volume create, 10001:10001 0700 after the worker's first start; Docker keeps it under /var/lib/docker, which is root:root 0710). The repository install runs the same image as the host user (user:) with data/state/ bound over that directory, as before. What is not claimed, as above: whoever may run Docker can read the volume and .env, and mount the state elsewhere; on Linux that is every member of the group docker.

One worker, by the lock elo.worker (B101)

The worker's start is, in this order: 1. the check of the state directory (and, in the repository install, the ticket); 2. the state's home (ingest.state_home: host for the repository install, volume for the packaged one; a worker whose kind is not the row's takes no lock, makes no call, marks no account absent and says the way out: the repository install's exits, and make up prints that line; the packaged one waits, saying it in its log and in make status, and goes on when the row is set); 3. the session advisory lock elo.worker on the pace store's own connection, token or not: a worker that cannot take it starts neither lane, runs no job, makes no call and is not healthy, says once a minute that another worker holds it and takes it when it is free; 4. the lanes and the scheduler, healthy from here. The main loop asks the lock at every poll; a worker that finds it gone stops at once with an error and leaves the egress (its lock directory and the handoff record) to its successor. The pace store refuses to reserve, complete or recover a call without the lock; before each send the client asks the lock again, and again where more than 2 s have passed on the boot-time clock since it asked; a call has one deadline of 130 s. A successor that finds the egress's owner record left waits 150 s on its clock from the moment it took the lock before it takes the egress over (more than the 130 s and the 2 s); one that finds none (its predecessor stopped gracefully) takes it at once. One call already decided may still leave after the lock is lost, where the process is stopped in the instant between its last reading of the clock and the write to the socket and loses its session meanwhile: §2.4's residual. A stop of Docker's daemon (a restart of the machine) stops the containers side by side. PostgreSQL can stop before the worker finishes: if the worker loses its lock it leaves the egress, and the successor waits 150 s before taking it over. A worker that finishes gracefully first leaves no owner record and needs no takeover wait. Docker's restart policy gives no dependency order; B101 measured the database stopping in about a second and the services returning by their policies. make down stops the worker before the database and hands the egress over as before. The one-shot commands that must run without a worker (B102, B104) take the same lock.

Host sleep in a VM. Linux's boot-time clock counts process stops and Linux suspend, but the clock measured inside Colima does not count the Mac host's sleep. In that case the lock relies on the worker, its successor and PostgreSQL running under one kernel: their clocks and the database session pause and resume together, retaining the lock during host sleep. A database outside the worker's VM would not meet this condition. During the 150 s takeover wait, Eloverblik jobs remain unclaimed, spending no attempts; other jobs continue. The egress is retried at lock+150 s on the boot clock. On lock loss health is withdrawn as soon as the main loop learns of it (at its next poll when idle, at most one call's 130 s later under a call in flight) and the main loop claims no further job; the declaration lane finishes its running job before exit. Holding elo.worker alone therefore does not prove that the earlier worker has finished every database write.

What the check cannot see

On a pass-through mount (this Mac: Colima, virtiofs) the container cannot see the host's owner of a file or its ACL, so the worker's half judges the link and the mode bits alone, and those with a lag of a few seconds. A change made on the host between the host check and the worker's start (at most the ticket's lifetime, 120 seconds) **or after it** — an ACL added to the state directory or a component above it, a component above the state directory opened to group or others — is therefore not seen by the running worker. Unsafe host facts invisible through the mount are re-evaluated on the next make up, and where that refuses it stops the running worker; a safe replacement of the directory can pass that new check. On an enforcing mount (Linux) the worker also compares the owner, but a component above its mount point is invisible to it as well. The owner of the machine is trusted (N9): someone who can run Docker, change the VM or edit files as that user can mount the state directory elsewhere, forge a ticket or start a container without make up, and nothing here claims to stop that. What is claimed is that every start of the worker by the supported route is preceded by a host check of at most 120 seconds before it, that a ticket authorizes at most one start and none after a later make up, a make down or the end of the launch it was made for, unless the revocation could not remove it or could not reach the state directory, which is reported as such, or the recipe was ended by SIGKILL or a power loss (a ticket then authorizes only until its 120 seconds are over), and that the worker's own writes go to the directory that was checked (on macOS a new token file is first created empty, 0600 and without an ACL, by the directory's current path, and is used only once it is proven to be the entry of the verified descriptor).

Rules the stack enforces

RuleWhereChecked by
Loopback onlyCompose publishes on 127.0.0.1; the API refuses to start when ELO_PUBLIC_ADDRESS is not localhost, *.localhost or a loopback IP (elo_api.settings)test_local_mode.py, test_stack.py, smoke.py
Host allowlistCaddy and the API answer 421 to every Host but elo.localhost, localhost and 127.0.0.1 on the published portthe same
Client headerThe API answers 403 to a request without X-Elo-Client: web, reads and unknown paths included; it sends no CORS headers, so a page on another origin cannot pass the preflight. Caddy passes the header through and adds nonethe same
The tokenELOVERBLIK_REFRESH_TOKEN is under environment: of worker alonetest_stack.py (docker compose config), smoke.py (the containers' configuration and running environment)
Roleselo_owner (owns, migrates), elo_api (reads), elo_worker (the queue, the recorder, the pacer functions and the two reading functions; no write on the three tables of readings). None is a superuser or bypasses row-level security, none can create anything but the owner, none is a member of a roletest_migrations.py, smoke.py
One migration chainservices/api/migrations/: one chain from B03's 0001_schemas_ops, one head, forward-only. Two heads (two first revisions included) fail CI (test_two_heads_fail) and the runner refuses to upgradetest_migrations.py
Jobs are discovered and dispatchedA job is found by its module, taken from a JobQueue and run once; a failure records the exception's class name only. The PostgreSQL queue (PostgresQueue on ops.job) runs it in the worker; its crash tests are in test_queue.pytest_dispatch.py (a fake queue), test_queue.py (PostgreSQL, real worker processes killed), smoke.py (the worker found its jobs)
One worker, one state mountFixed container name, 150 s grace period, /data/state in the worker alone; the mkdir of one directory under egress/ from container and host at once has exactly one winner in each of 100 rounds; both sides must complete and their attempts, first to last, overlap in time (B06bv5-11). Each side adds its own random offset in [0, 30 ms) to every round's instant (RACE_JITTER: more than the few milliseconds by which one side is steadily late, less than the rounds' 50 ms gap), so that neither side is always first. The judge proves that both sides ran and that their sweeps overlapped by their own clocks, and prints the host won n rounds, the container m; on Linux (the deployment's platform) it requires both above zero (B06bv6a-24), so that a round was shown to be contested; on another platform a one-sided race is printed as such and does not fail (a VM's file sharing can make one side always late). It proves nothing across a host and a container whose clocks disagree (B06bf7 addendum A6)test_stack.py (resolved file), smoke.py (live)
LogsUvicorn's access log is off (--no-access-log): it writes the full path and query string; no request line is loggedtest_server_logging.py runs the image's CMD and scans its output after accepted and refused requests

Adding a job

A file in services/worker/src/elo_worker/jobs/ with KIND = "…" and run(context, payload) -> dict. Discovery finds it; no registry is edited. context is what the queue hands to the handler (with B03's PostgreSQL queue, the claim's connection). A failed job is reported by the exception's class name, never its text.

Two lanes (B19). The worker runs the declaration's two jobs (eds-load, eds-monthly-repull) in a thread of their own, which claims only those kinds (PostgresQueue(kinds=…)); every other job runs in the main loop (other_than=…), which alone holds the Eloverblik runtime (the egress, the client) and asks the scheduler. A declaration job sleeps in the process through Energi Data Service's spacing and cooldowns (90 minutes on the first load); it no longer holds the daily run back. One Eloverblik request in flight (§5.2) is untouched: no Eloverblik job runs in the declaration lane. A new job kind runs in the main loop unless it is added to EDS_KINDS (elo_worker/__main__.py), which only a job that never calls Eloverblik may be. A graceful stop ends a declaration job's wait within seconds (B19f, elo_worker.stopping): the reserved start is given back, no request is recorded, and the job goes back to the queue with every attempt it had (its run closed as {"interrupted": true}, its max_attempts raised by one, at most to the column's 10, so from the seventh interruption of one job an attempt is spent); a job in the middle of a call or of applying a window finishes that first.

A release (B100)

make release VERSION=0.1.0 is python -m elo_devtools.release build. The version is the tag's and no file's: the command refuses a version that is not X.Y.Z, a tree that git status shows as not clean, a checkout that is not the tag vX.Y.Z, and, for a patch (Z above 0), a services/api/migrations tree or a deploy/compose.yaml that differs from vX.Y.0's (image references aside). REHEARSAL=1 allows an untagged checkout and is not a release. The tag is made by the sender afterwards; nothing here tags or pushes, and .github/workflows/release.yml runs only when a tag v* is pushed.

ImageDockerfileHolds
elo-api (also migrate)services/api/Dockerfile, last stage releasethe virtual environment with elo_api installed as a package, the migrations at the interpreter's lib/pythonX.Y/migrations (where elo_api/db/migrate.py looks: parents[3]), /licenses/
elo-workerservices/worker/Dockerfile, last stage releasethe virtual environment with elo_worker and elo_api, user 10001, /data/state 0700, /licenses/
elo-webdeploy/web.DockerfileCaddy, deploy/Caddyfile, the web build with its own licenses/, /licenses/
elo-demodeploy/demo.Dockerfile, on elo-workerelo_devtools and fixtures/factors/ on top of the worker

The first two Dockerfiles have a stage workspace besides: the repository install's image, as it was (the whole workspace in /app, editable, with uv). deploy/compose.yaml builds target: workspace, so make up, make demo-load (which runs tools/src from /app) and the stack check are unchanged by the release's lean images. The image's version is the build argument VERSION, its environment ELO_VERSION (read by elo_api.settings; meta.context answers it as product.version; unset, empty, 0.0.0+dev), its labels org.opencontainers.image.version, .revision, .created and org.eloverblik.built-by (CI or machine).

python -m elo_devtools.release content IMAGE KIND (api, worker, web, demo) is the content test of §2.2: it lists the files of a container made from the image (never started) and of its base image (listed itself, for the architecture of the image under test, from the FROM of the Dockerfile's last stage). **Every path of the image is the base image's or in the image's closed product set, and anything else fails wherever it lies** (a /secrets, /.cache, /docs or /tests at the root included): the product's set is the licence files and the list of the base's packages, an empty /app (the demo's fixtures/factors/ exactly as the checkout has it), an empty /data/state, the virtual environment /opt/venv (the product's own packages and the api's migrations exactly as the checkout has them) and, for elo-web, Caddy's file and /srv/web, which holds exactly the files the build emitted (/licenses/web-build-manifest.txt, written by the build, each with the SHA-256 the build recorded: a file appended to or rewritten after the build fails) and the public assets. It also fails on a missing licence file, a name .env* anywhere, the owner's notes (orchestration, reviews, .remember, .s4b-source, .git) at any path, uv, elo_devtools where it does not belong. make release then plants files in copies of each image (the root, the licences, the copied trees) and refuses unless the test fails each one, for every architecture it builds. .dockerignore stays a list of what is admitted, with the notes and caches excluded at every depth; the tests plant files under every admitted tree and list what reaches a build.

The release's Compose file is generated from deploy/compose.yaml by the rows of elo_devtools.release.DIFFERENCES and by nothing else: unlisted_differences is what the test calls, and a row of another epic is one append (B102's tools and admin, B104's demo-load). The stack check in its release mode is deploy/smoke.py --release <folder> --arch <a>: the generated file in an empty folder, the image file loaded, a sentinel as .env's line, and the checks of both installs as they are; the host directory's, the ticket's and make's run in the repository mode alone.

Configuration

deploy/dev.env holds public development passwords for the three roles and PostgreSQL's superuser, and nothing else. Settings of the API: DATABASE_URL, ELO_PUBLIC_ADDRESS, ELO_PORT, ELO_DATABASE_POOL_MAX, ELO_VERSION (set by the image: X.Y.Z or 0.0.0+<commit>; anything else stops the start). Of the worker: DATABASE_URL, ELO_WORKER_POLL_SECONDS, ELOVERBLIK_REFRESH_TOKEN, ELO_DEMO (1: the demo stack and the stack check, where the scheduler queues no declaration job). Of migrate: ELO_ADMIN_DATABASE_URL and the three passwords.

Kilde: docs/stack.md i løsningens repository.