Skip to main content

Crate ch_rds

Crate ch_rds 

Source
Expand description

§ch-rds

Runtime setup and local development tools for Rust apps.

§Installation

[dependencies]
ch-rds = "0.2.1"

Requires Rust 1.99 or newer.

§Usage

Runtime::bootstrap finds the project and loads its environment files. Runtime::load resolves web listener addresses, MariaDB connection URLs, and SpacetimeDB connections.

Local connections can start the project’s Docker Compose services. Configure database connections explicitly in production.

Set ENV_FILE to choose an environment file. PORT overrides the web listener port. CronjobManager runs background jobs at regular intervals.

§Features

FeatureIncludes
devFrontend and backend commands through ProjectProfile and run_project
btcpayLocal BTCPay setup and the dev feature

The development runner provides watch, build, and serve commands. Watch mode requires watchexec.

See the API documentation for configuration options.

§License

Sustainable Use License 1.0.

Modules§

cronjob
Background-job scheduling and execution primitives.
dev
Development commands for building and running an application workspace.

Structs§

LocalStack
Settings for the bundled local Docker Compose stack.
MariaDB
Configures how a MariaDB resource should be resolved for the runtime.
Project
Filesystem layout discovered for the running application.
Runtime
Discovers application settings and prepares runtime resources.
SpacetimeDB
Configures how a SpacetimeDB endpoint should be resolved for the runtime.
SpacetimeDbConnection
Resolved SpacetimeDB endpoint plus the private module-owner token when the shared runtime manages a local development module.
WebBind
Configures the app web listener address for the runtime.

Enums§

RuntimeEnvironment
Selects whether the runtime may manage local development services.
RuntimeError
Failures while discovering a project or loading its resources.

Traits§

Resource
Loads one resource using the selected runtime policy and project.