Commit Graph
230 Commits
Author SHA1 Message Date
Sebastian Lorenz a6f3a52936 feat(docker): make build contexts from a directory and its .dockerignore
A new DockerBuildContext service, built over FileSystem and Path, turns a
directory into the tar stream images.build takes, as docker build does: the
Dockerfile's own ignore file or else .dockerignore, read with core's
IgnoreFile.dockerignore and walked with FileSystem.glob; the Dockerfile and
the ignore file always sent, the Dockerfile first for BuildKit; files,
directories and unfollowed symbolic links owned by root. NodeDocker's layers
provide it. A malformed ignore file or a file that fails to read is the new
DockerError reason InvalidBuildContext.
2026-11-09 07:06:52 +00:00
Effect Bot ca3a4f8820 feat(docker): speak Docker Engine API 1.52 only
- generate the schemas from moby's api/docs/v1.52.yaml, and drop the pre-1.52 /system/df patch
- send every request at /v1.52 after one unversioned /version check that the Engine serves it;
  UnsupportedApiVersion reports the Engine's range and asks to upgrade an old Engine
- remove negotiation, the apiVersion setting, ApiVersions gates and OptionNotSupported
- accept DOCKER_API_VERSION only as 1.52
- remove post-1.52 surface: image attestations, the images identity query, keep-storage; events as x-ndjson
- DockerConfig hashes context names with effect/crypto's Digest, after main replaced effect/Crypto
- docs, codegen notes and the changeset state the fixed support policy
2026-11-09 06:50:04 +00:00
Tim Smart 9f61304547 test(docker): keep focused contract and integration coverage 2026-11-09 06:50:04 +00:00
Effect Bot 9ac42b5913 fix(docker): find the config directory in the platform's home, USERPROFILE on Windows
DockerConfig.layerFromEnv takes a homeVariable option, HOME by default, for
the config directory when DOCKER_CONFIG is unset. NodeDocker.layerFromEnv
passes USERPROFILE on Windows, as the CLI reads it through os.UserHomeDir.
2026-11-09 06:50:03 +00:00
Effect Bot 7ef0bbce0a feat(docker): named pipes, and handle output read in arrival order through one view
- Endpoint gains Npipe; parseHost reads npipe://, an empty path being the default pipe
- layerFromEnv takes the platform's default Endpoint; NodeDocker.layerFromEnv uses the named pipe on Windows
- NodeDocker reaches a named pipe through socketPath
- Handle.frames is the output in arrival order; all, stdout and stderr are views of it, read once
- DockerExec.run collects stdout and stderr from frames
2026-11-09 06:50:03 +00:00
Effect Bot 3c0f950a86 fix(docker): fix the review findings
- attach resolves its framing after owning the upgraded connection, so a failed inspect closes it
- plugin install removes the plugin only after its own pull succeeded
- push and tag reject a reference with a digest instead of dropping it
- every error response body is read up to 1 MiB, declared statuses included
2026-11-09 06:49:47 +00:00
Effect Bot 9a4eb6c1b0 refactor(docker): unexport unused internals, correct the layerFromEnv overrides docs 2026-11-09 06:49:46 +00:00
Effect Bot a06baba608 test(docker): reduce the suites to the accepted behavior
- unit suites cut from 117 to 55 tests, merged per behavior
- Swarm and plugin services covered by fake-engine round trips over DockerApi
- live suites cut to 11 tests; the docker:dind suites and their helper are removed
- the pinned API 1.44 CI rerun becomes one live decode test in DockerSystem
- CI no longer pulls docker:29-dind or busybox
- drop the platform-node DockerApi test, which duplicated the fake-engine round trip
2026-11-09 06:38:08 +00:00
Sebastian Lorenz f2a6ea7134 fix(docker): address the review of the stack
- DockerApi.Filters decodes through Schema.fromJsonString, so a server
  given malformed filters fails with a SchemaError, not a defect.
- DockerConfig formats a host as the CLI writes it (formatHost), for
  its proxy lookup and DockerEngine's ConnectionFailed target alike,
  instead of two copies.
- DockerPlugins.install takes its options inline: InstallOptions was a
  named type for one API.
- NodeDocker's tests return scoped effects to it.effect instead of
  wrapping them in Effect.scoped.
- The changeset is one sentence; the detail belongs in the PR.
- DOCKER.md and UnsupportedScheme say that ssh:// is planned on top of
  Effect's SSH client, DOCKER.md shows a stub HttpClient for checking
  what code sends, and DockerEngine.client's doc names a failed
  negotiation among its failures.
2026-11-08 20:21:54 +00:00
Sebastian Lorenz aa3bece1db feat(docker): resolve registry credentials in DockerRegistryAuth
Registry credentials move out of DockerEngine into their own service,
DockerRegistryAuth, with one method: the credential for a registry, or
undefined for anonymous. Its layer resolves them as the Docker CLI
does, from the DockerConfig, running credential helpers through the
ChildProcessSpawner, as the engine did before.

DockerEngine is now only the connection: DockerEngine.make needs just
the DockerConfig, and no longer a ChildProcessSpawner. DockerImages,
DockerPlugins and DockerServices require DockerRegistryAuth, and so
does Docker.layer. NodeDocker's layers provide it, with helpers run as
Node.js child processes; to resolve credentials another way, such as
minting short-lived tokens, provide the service yourself.
2026-11-08 20:21:53 +00:00
Sebastian Lorenz 76974ac1b3 feat(docker): one set of error classes for DockerApi and DockerError
DockerApi's error responses and DockerError's response reasons were two
classes per status, translated one to one. They are now one set: each
of BadRequest, Unauthorized, Forbidden, NotFound, Conflict,
PreconditionFailed, TooManyRequests, ServerError, NotImplemented,
Unavailable and SwarmUnavailable is a Schema.TaggedError with the
Engine's { message } body and a status getter, declared by DockerApi
and used as the reason as it is decoded.

The operation that failed moves from the reasons to DockerError's
operation, so a reason is only what the Engine said. A DockerError that
already names an operation keeps it.

Swarm endpoints declare their error responses with a SwarmErrors
middleware whose 503 is SwarmUnavailable, which replaces the
SwarmEndpoint annotation and the client's remap of Unavailable.
2026-11-08 20:21:52 +00:00
Sebastian Lorenz 30dfb1b8a5 feat(docker): add images and registry credentials
DockerImages covers list, inspect, history, attestations, tag, remove,
prune, search, commit, distribution, save, load, pull, push and import,
each an endpoint of DockerApi's Images group: platforms and the padded
base64url X-Registry-Auth header are schemas, and the service turns an
ImageReference into the Engine's fromImage and tag. The engine resolves
credentials as the Docker CLI does, with one registry normalization,
an exact helper "not found" match and a helper timeout; every registry
operation sends X-Registry-Auth. Registry headers and secret query
parameters are redacted in spans.
2026-11-08 20:21:51 +00:00
Sebastian Lorenz 70bca67c34 feat(docker): add containers, exec, networks and volumes
Every operation is an endpoint of DockerApi's groups, whose schemas carry
the wire mapping (renamed query keys, durations, times, header-borne results,
version gates as annotations); service methods only reshape arguments.
Logs demultiplex the Engine's stream framing, attach and exec start run
over core's HTTP upgrade, and archives stream as tar request and
response bodies.
2026-11-08 20:21:33 +00:00
Sebastian Lorenz 2ad1e253a0 feat(docker): add the engine, configuration, system service and NodeDocker
DockerConfig resolves the client's configuration as plain data, statically or
as the Docker CLI does; a malformed config.json auth entry now fails, as it
does in the CLI. DockerEngine wraps one HttpClient: lazy, cached API version
negotiation, the configured headers, and connection failures as DockerError.
Exec and attach will use HttpClient upgrades, so there is no separate dialer.
ConnectionFailed carries the Engine's address instead of the Endpoint, so TLS
keys never reach errors or logs, and its hints come from Node error codes.
DockerSystem is the one public ping. NodeDocker builds the engine over a
node:http client, which sets no timeouts and supports upgrades over unix
sockets and TLS.

DockerApi defines the Engine API as HttpApi endpoint groups, one per
area, with DockerApi as the HttpApi of them all; the services are clients
of their group, and each later commit adds its groups. The groups
describe what the client sends, with unversioned paths, and every group
declares the Engine's error responses with the EngineErrors middleware:
moby's status table, from which the services' DockerError reasons come,
naming the operation. Requests outside DockerApi check their status with
the same table.
2026-11-08 20:21:33 +00:00
effect-botandTim 13c0e778ce fix(sql): keep driver services in requirements when SqlClient is provided (#10387)
Co-authored-by: Tim <hello@timsmart.co>
2026-11-05 00:10:16 +00:00
effect-bot da52437f6e Add retention-based cleanup of completed cluster requests (#10267) 2026-11-04 15:52:02 +13:00
effect-bot 8968d09eaf Close unupgraded upgrade connections in NodeHttpServer (#10360) 2026-11-03 23:39:06 +00:00
effect-bot 5806facde9 Document HTTP server handler interruptibility (#10302) 2026-11-03 12:44:44 +13:00
Tim f1f1092d7c Fix type errors reported by TypeScript 7.1 (#10306) 2026-11-03 11:58:49 +13:00
effect-bot 506eef143b Version Packages (#10212) 2026-11-02 16:59:53 +13:00
Tim b0a1ceebcd Update repository dependencies (#10257) 2026-11-02 16:21:02 +13:00
Hoishin ee4f7104c3 deps: pin platform shared package versions (#10237) 2026-11-02 11:33:52 +13:00
effect-bot 6b70da9d05 Remove duplicate tests and speed up slow test files (#10214) 2026-10-31 19:45:17 +13:00
effect-bot bc492f0965 Version Packages (#10144) 2026-10-30 21:25:49 +00:00
Tim 000cdbf374 Deflake the SqlRunnerStorage test for acquiring after the lock session ends (#10180) 2026-10-30 16:49:21 +13:00
effect-bot dee85c443a Make NodeRedis subscriber and reserved-connection acquisition interruptible (#10156) 2026-10-30 11:44:29 +13:00
effect-bot 7a4f6277c0 Raise NodeRedis redis peer minimum to 5.1.0 (#10153) 2026-10-30 10:59:20 +13:00
e1b4d37efe Fix NodeRedis scope finalization for pending connections and commands (#10100)
Co-authored-by: Bazyli Brzóska <563469+niieani@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Effect Bot <tech-ops@effectful.co>
2026-10-30 09:05:53 +13:00
effect-bot 9a91b1926a Version Packages (#10038) 2026-10-29 03:41:32 +00:00
effect-bot 9a48f6530b Tighten Node WebSocket changeset and comments (#10091) 2026-10-29 16:31:41 +13:00
effect-bot 472c469ce1 Require Node 22.19 and use the global WebSocket for Node clients (#10084) 2026-10-29 16:31:41 +13:00
Tim fb5dbee799 Release a frozen runner's MySQL shard locks after shardLockExpiration (#10093) 2026-10-29 16:15:59 +13:00
Tim 8309b94770 Restore idle_session_timeout before returning the PostgreSQL shard-lock connection to the pool (#10095) 2026-10-29 16:15:00 +13:00
effect-bot 438ce725e9 Encode NodeHttpClient FormData bodies with the global Response (#10081) 2026-10-29 14:29:03 +13:00
Jon PowersandEffect Bot ce9e999054 HttpIncomingMessage: preserve leading question marks in form field names (#10067)
Co-authored-by: Effect Bot <tech-ops@effectful.co>
2026-10-29 00:34:43 +00:00
Jon PowersandEffect Bot 8e668fe1ce HttpIncomingMessage: preserve BOMs in URL-encoded bodies (#10065)
Co-authored-by: Effect Bot <tech-ops@effectful.co>
2026-10-28 23:50:33 +00:00
effect-bot 19d36b8948 Convert Node HTTP server request headers instead of casting (#10071) 2026-10-29 10:24:37 +13:00
effect-bot 8938b19446 Make KeyValueStore.layerFileSystem remove succeed for missing keys (#9943) 2026-10-28 15:48:48 +13:00
effect-bot 9a07ebc550 Allow ordinary success responses alongside HttpApi upgrades (#9945) 2026-10-28 15:48:48 +13:00
Tim 93895b9899 Add keys to KeyValueStore (#9844) 2026-10-28 15:48:48 +13:00
effect-bot 892fb79e2d Default Bun idle timeouts to off and document streaming timeouts (#9705) 2026-10-28 15:48:48 +13:00
f40dc4e492 fix(http): send stored cookies only to the matching host (#9614)
Co-authored-by: Viacheslav <bezff@MacBook-Pro-3.local>
Co-authored-by: Effect Bot <tech-ops@effectful.co>
Co-authored-by: Tim Smart <hello@timsmart.co>
2026-10-28 15:48:48 +13:00
Sebastian LorenzandTim Smart 8f236683ad Replace effect/Crypto with per-family effect/crypto modules (#9126)
Co-authored-by: Tim Smart <hello@timsmart.co>
2026-10-28 15:48:48 +13:00
effect-botandTim Smart 66c796a089 Bound synchronous Node readable and socket drains (#9327)
Co-authored-by: Tim Smart <hello@timsmart.co>
2026-10-28 15:48:48 +13:00
effect-botandTim Smart 4f0fad1c9b Fix Redis persisted queue claim ownership (#9229)
Co-authored-by: Tim Smart <hello@timsmart.co>
2026-10-28 15:48:48 +13:00
effect-botandTim f97711f43f fix(persistence): isolate stores on KeyValueStore and Redis backings (#9223)
Co-authored-by: Tim <hello@timsmart.co>
2026-10-28 15:48:48 +13:00
2ae404530b Acknowledge discarded RPC calls before running handlers (#9182)
Co-authored-by: Juliaan <76615135+schutzelaars@users.noreply.github.com>
Co-authored-by: Effect Bot <tech-ops@effectful.co>
2026-10-28 15:48:48 +13:00
effect-bot b174739b6b Version Packages (#9757) 2026-10-28 15:38:36 +13:00
Tim 383716d04b Release a frozen runner's Postgres advisory shard locks after shardLockExpiration (#10037) 2026-10-28 15:25:03 +13:00
effect-botandJonathan Powers eedfb27f00 Release discarded HTTP redirect responses (#10036)
Co-authored-by: Jonathan Powers <jon@powers.dev>
2026-10-28 14:47:56 +13:00