2026-04-06 23:47:42 +01:00
|
|
|
use std::path::PathBuf;
|
|
|
|
|
|
feat(wfe-server-protos): add gRPC service definitions for workflow server
13 RPCs in wfe.v1.Wfe service: RegisterWorkflow, StartWorkflow,
GetWorkflow, CancelWorkflow, SuspendWorkflow, ResumeWorkflow,
SearchWorkflows, PublishEvent, WatchLifecycle (stream),
StreamLogs (stream), SearchLogs, ListDefinitions.
2026-04-01 14:35:57 +01:00
|
|
|
fn main() -> Result<(), Box<dyn std::error::Error>> {
|
|
|
|
|
let proto_files = vec!["proto/wfe/v1/wfe.proto"];
|
|
|
|
|
|
2026-04-06 23:47:42 +01:00
|
|
|
let out_dir = PathBuf::from(std::env::var("OUT_DIR")?);
|
|
|
|
|
let descriptor_path = out_dir.join("wfe_descriptor.bin");
|
|
|
|
|
|
feat(wfe-server-protos): add gRPC service definitions for workflow server
13 RPCs in wfe.v1.Wfe service: RegisterWorkflow, StartWorkflow,
GetWorkflow, CancelWorkflow, SuspendWorkflow, ResumeWorkflow,
SearchWorkflows, PublishEvent, WatchLifecycle (stream),
StreamLogs (stream), SearchLogs, ListDefinitions.
2026-04-01 14:35:57 +01:00
|
|
|
let mut prost_config = prost_build::Config::new();
|
|
|
|
|
prost_config.include_file("mod.rs");
|
|
|
|
|
|
|
|
|
|
tonic_prost_build::configure()
|
|
|
|
|
.build_server(true)
|
|
|
|
|
.build_client(true)
|
2026-04-06 23:47:42 +01:00
|
|
|
.file_descriptor_set_path(&descriptor_path)
|
feat(wfe-server-protos): add gRPC service definitions for workflow server
13 RPCs in wfe.v1.Wfe service: RegisterWorkflow, StartWorkflow,
GetWorkflow, CancelWorkflow, SuspendWorkflow, ResumeWorkflow,
SearchWorkflows, PublishEvent, WatchLifecycle (stream),
StreamLogs (stream), SearchLogs, ListDefinitions.
2026-04-01 14:35:57 +01:00
|
|
|
.compile_with_config(
|
|
|
|
|
prost_config,
|
|
|
|
|
&proto_files,
|
|
|
|
|
&["proto"],
|
|
|
|
|
)?;
|
|
|
|
|
|
|
|
|
|
Ok(())
|
|
|
|
|
}
|