Skip to main content

Crate zlayer_types

Crate zlayer_types 

Source
Expand description

Shared wire types for the ZLayer platform.

This crate is the SDK-facing types crate: API DTOs, OCI image references, and other serde-friendly wire shapes consumed by both the daemon and clients. It is intentionally lightweight — no axum, no tokio, no reqwest. Heavier server-side abstractions live in zlayer-api, zlayer-core, and friends.

Re-exports§

pub use scratch::Scratch;
pub use scratch::ScratchFile;

Modules§

api
Wire-type modules. Each maps to one logical area; downstream crates import via pub use zlayer_types::<area>::....
auth
Auth wire DTOs.
builder
Shared types for build-backend dispatch and sidecar wire protocol.
client
Client-facing wire types shared between the ZLayer daemon and SDK clients (CLI, zlayer-docker, zlayer-py, future language SDKs).
cluster
Daemon-level cluster mode selection.
image_ref_serde
Serde helpers to (de)serialize an ImageReference as its OCI-spec canonical string form ([host[:port]/]name[:tag][@digest]) instead of the default struct shape {registry, repository, tag, digest}.
jwt
JWT claims and related auth wire types.
overlay
Overlay-network configuration types shared across ZLayer crates.
overlayd
IPC wire protocol between the main zlayer daemon and zlayer-overlayd.
scratch
RAII scratch directory and file types anchored at the ZLayer data dir’s tmp/ subdirectory. Constructed via [zlayer_paths::ZLayerDirs::scratch_dir] and [zlayer_paths::ZLayerDirs::scratch_file]. These wrap tempfile’s handles so call sites can name their return type without pulling in tempfile directly.
secrets
Secrets domain wire/storage types.
spec
ZLayer V1 Service Specification
storage
Storage Stored* wire types.

Structs§

ImageRef
Image reference that preserves the user’s RAW input string alongside the parsed canonical ImageReference.
ImageReference
Canonical OCI image reference.

Functions§

image_ref_candidates
Candidate (name, reference) spellings for the LITERAL image string, in priority order, for cross-spelling lookups in a local store.
image_str_is_unqualified
Standalone form of ImageRef::is_unqualified operating on a raw string.