junction_api/
kube.rs

1//! Types and re-exports for converting Junction types to Kubernetes objects.
2//!
3//! When the `kube` feature of this crate is active,
4//! [Route](crate::http::Route)s and [Backend](crate::backend::Backend)s can be
5//! converted into Kubernetes API types. To help avoid dependency conflicts with
6//! different versions of [`k8s-openapi`](https://crates.io/crates/k8s-openapi)
7//! and [`gateway-api`](https://crates.io/crates/gateway-api), this crate
8//! re-exports its versions of those dependencies.
9//!
10//! ```no_run
11//! // Import re-exported deps to make sure versions match
12//! use junction_api::kube::k8s_openapi;
13//!
14//! // Use the re-exported version as normal
15//! use k8s_openapi::api::core::v1::PodSpec;
16//! let spec = PodSpec::default();
17//! ```
18//!
19//! This crate does not set a [`k8s-openapi` version feature](https://docs.rs/k8s-openapi/latest/k8s_openapi/#crate-features),
20//! application authors (but not library authors!) who depend on `junction-api`
21//! with the `kube` feature enabled will still need to include `k8s-openapi` as
22//! a direct dependency and set the appropriate cargo feature.
23
24mod backend;
25mod http;
26
27pub use gateway_api;
28pub use k8s_openapi;