pub struct ComputeConfig {Show 20 fields
pub bridge: String,
pub subnet: String,
pub vcpus: u32,
pub mem_mib: u32,
pub kernel_signing_pubkeys: Vec<String>,
pub kernel_allowed_hashes: Vec<String>,
pub region: Option<String>,
pub docker_endpoint: DockerEndpoint,
pub docker_volume_mode: DockerVolumeMode,
pub docker_ephemeral_timeout_secs: u64,
pub sql_shim_url: Option<String>,
pub blob_shim_url: Option<String>,
pub blob_shim_max_object_bytes: Option<u64>,
pub managed_db_privilege: ManagedDbPrivilege,
pub internal_dns: bool,
pub dns_upstream: String,
pub dns_domain: String,
pub client_image_rootfs: BTreeMap<String, String>,
pub pg_client_image: Option<String>,
pub mysql_client_image: Option<String>,
}Expand description
compute section — opt-in compute backends. Present
⇒ serve registers the backends this node can offer and advertises them to
the scheduler; backends are capability-detected (container on Linux, remote
docker when a daemon is reachable, VMM when /dev/kvm exists).
Fields§
§bridge: StringBridge the container veths / VM taps attach to (default br-boatramp).
subnet: StringGuest IP subnet (default 10.0.0.0/24).
vcpus: u32vCPUs this node advertises as schedulable (0 ⇒ detect from the host).
mem_mib: u32Memory (MiB) this node advertises as schedulable (0 ⇒ a 1 GiB default).
kernel_signing_pubkeys: Vec<String>Static kernel-signing public keys ("<alg>:<hex>") — the trust anchor
for the posture-scaled kernel bar. Under multi-tenant, a dynamically-
selected default kernel must carry a signature verifying against one of
these. Host-access-gated (never in the KV tier); changing it needs a
restart. Empty ⇒ no kernel may be signed-verified (strict posture then
accepts none).
kernel_allowed_hashes: Vec<String>Static allow-list of kernel content hashes (sha256 hex) a dynamic
default may select under multi-tenant. Host-access-gated. Empty ⇒ no
kernel is allow-listed.
region: Option<String>This node’s region tag (FA-8). Advertised on the compute Node so a
gateway routing to a compute:-backed workload with --lb nearest sends
each request to the nearest replica by its node’s region — no manual
--region map. None ⇒ region-agnostic.
docker_endpoint: DockerEndpointHow the remote-Docker backend reports a workload’s reachable endpoint.
published (default) publishes the container port on 127.0.0.1:<ephemeral>
so a host-native serve reaches it on any daemon (incl. Docker Desktop /
macOS, where the bridge IP is not host-routable); bridge routes to the
container bridge IP directly (only when serve shares the daemon’s network).
docker_volume_mode: DockerVolumeModeHow the remote-Docker backend backs a workload’s persistent volumes.
named (default) attaches a daemon-managed docker volume by name (portable
across daemons + Docker Desktop / macOS); bind bind-mounts a host directory
under <data_dir>/compute/volumes/<name> (local daemon only).
docker_ephemeral_timeout_secs: u64Wall-clock backstop (seconds) for one project export/import client run
(run_ephemeral: a pg_dump/pg_restore container). 0 (default) keeps the
backend’s generous built-in default (6h). Raise it for a very large migration so
the backstop never kills legitimate work; the real unreachable-DSN hang is bounded
far tighter by the client’s own connect timeout.
sql_shim_url: Option<String>Guest-reachable base URL of the compute sql-shim (PLAN-compute-bindings) —
e.g. http://10.0.0.1:8081 (the compute bridge gateway) or the docker bridge
gateway. Set ⇒ a workload’s --bind sql reaches the managed database through a
listener bound on the host:port this URL names (the bridge-gateway IP /
loopback — NOT all interfaces; a token-gated tenant-SQL data plane must not be
off-node reachable). None (default) ⇒ compute sql bindings off.
blob_shim_url: Option<String>Guest-reachable base URL of the compute blob-shim (PLAN-compute-bindings) —
e.g. http://10.0.0.1:8082 (the compute bridge gateway) or the docker bridge
gateway. Set ⇒ a workload’s --bind blob reaches the SAME per-site
hblob/{qualified-site}/… blob namespace a wasi:blobstore handler sees, through a
listener bound on the host:port this URL names (the bridge-gateway IP /
loopback — NOT all interfaces; the token-gated hblob/{site}/ data plane must not
be off-node reachable). None (default) ⇒ compute blob bindings off. The direct
analogue of Self::sql_shim_url.
blob_shim_max_object_bytes: Option<u64>Per-object PUT ceiling (bytes) for the compute blob-shim — bounds a single write so a
compromised/buggy workload cannot exhaust node/bucket storage with one unbounded PUT (413
on an oversize PUT). None (default) ⇒ the shim’s built-in default (5 GiB, S3’s single-PUT
limit); Some(0) ⇒ unlimited.
managed_db_privilege: ManagedDbPrivilegePrivilege strategy for a managed database’s stock image on a shared-kernel
backend (see ManagedDbPrivilege). rootless by default.
internal_dns: boolPer-project internal DNS (service discovery): run a lightweight resolver
on the bridge gateway so a guest can reach peers by name (<workload> /
<workload>.<project>.<dns_domain>) instead of a numeric IP, scoped to its
own project. Default on — it activates only when the container backend +
bridge come up, so a node without them is unaffected. false disables it and
leaves each image’s own /etc/resolv.conf.
dns_upstream: StringThe upstream resolver the internal DNS forwards non-internal queries to
(external names + non-A/AAAA types), so the resolver is the guest’s single
nameserver. "host:port"; default 1.1.1.1:53.
dns_domain: StringThe internal DNS suffix names live under (<workload>.<project>.<dns_domain>);
also the search domain written into each container’s resolv.conf. Default
boatramp.internal.
client_image_rootfs: BTreeMap<String, String>Air-gap override for the project export/import client images the native
container backend runs via run_ephemeral (a pg_dump/pg_restore/mysqldump/
mysql/psql one-shot). Maps a client image reference → a preloaded rootfs, so
an export/import can run with NO registry pull on an isolated node. The value is
either an absolute host path to an already-unpacked rootfs directory (used
verbatim), or a Storage blob hash of a rootfs tar the backend stages like any
RootSource::Tar. Empty (the default) ⇒ every client image is pulled + built
on demand over the registry HTTP API (daemonless), the same path materialize
uses. Only the native container backend consults this; the remote docker
backend pulls through its daemon. Example:
[compute.client_image_rootfs]
"pgvector/pgvector:pg16" = "/var/lib/boatramp/client-rootfs/pg16"
"mysql:8.0" = "9f86d0818...<rootfs-tar-blob-sha256>"pg_client_image: Option<String>Digest-pin / override for the Postgres client image the project export/import + sql exec
seams run via run_ephemeral (pg_dump/pg_restore/psql). When set, this image reference is
used VERBATIM instead of the version-computed pgvector/pgvector:pg{major} tag — so an operator
can pin it by digest (pgvector/pgvector:pg16@sha256:<hex>) and have it accepted under the
multi-tenant posture (which refuses an un-pinned mutable-tag pull), with NO rootfs staging:
boatramp pulls + runs it through the normal on-demand path. The lighter-weight alternative to
Self::client_image_rootfs for a node with registry egress. None (default) ⇒ the computed
tag. Env: BOATRAMP_COMPUTE_PG_CLIENT_IMAGE.
mysql_client_image: Option<String>MySQL counterpart of Self::pg_client_image — pins/overrides the mysql:<maj.min> client
image for the export/import/sql exec run_ephemeral (mysqldump/mysql). Env:
BOATRAMP_COMPUTE_MYSQL_CLIENT_IMAGE.
Trait Implementations§
Source§impl Clone for ComputeConfig
impl Clone for ComputeConfig
Source§impl Debug for ComputeConfig
impl Debug for ComputeConfig
Source§impl Default for ComputeConfig
impl Default for ComputeConfig
Source§impl<'de> Deserialize<'de> for ComputeConfigwhere
ComputeConfig: Default,
impl<'de> Deserialize<'de> for ComputeConfigwhere
ComputeConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for ComputeConfig
impl RefUnwindSafe for ComputeConfig
impl Send for ComputeConfig
impl Sync for ComputeConfig
impl Unpin for ComputeConfig
impl UnsafeUnpin for ComputeConfig
impl UnwindSafe for ComputeConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more