Skip to content
This repository has been archived by the owner on May 22, 2024. It is now read-only.

Commit

Permalink
Remove Hardcoded k8s-openapi Version Feature (#13)
Browse files Browse the repository at this point in the history
  • Loading branch information
kflansburg authored Jun 1, 2021
1 parent 5c1565f commit 7c0f26f
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
18 changes: 18 additions & 0 deletions docs/community/developers.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,24 @@ We use `cargo` to build our programs:
$ cargo build
```

Krator is a library crate, meaning that you cannot run Krator
directly, but must import it into other "binary" crates which can
then be run. To see an example of using Krator in this way,
check out the [moose example](/krator/examples/moose.rs).

Krator does not configure `k8s-openapi` to use a specific version of
Kubernetes. You will need to select a version and enable its feature
when building your application:

```
[dependencies.k8s-openapi]
version = "0.11"
default-features = false
features = ["v1_20"]
```

Krator is tested against Kubernetes v1.20.

### Building without openssl

If you are on a system that doesn't have OpenSSL (or has the incorrect version),
Expand Down
10 changes: 9 additions & 1 deletion krator/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ async-trait = "0.1"
anyhow = "1.0"
tokio = { version = "1.0", features = ["fs", "macros", "signal"] }
tokio-stream = { version = "0.1", features = ['sync'] }
k8s-openapi = { version = "0.11", default-features = false, features = ["v1_20"] }
kube = { version = "0.55", default-features = false }
kube-runtime = { version = "0.55", default-features = false }
serde = { version = "1.0", features = ["derive"] }
Expand All @@ -49,6 +48,15 @@ tracing = { version = "0.1", features = ['log'] }
tracing-futures = "0.2"
rcgen = { version = "0.8.9", features = ["x509-parser", "pem"], optional = true }

[dependencies.k8s-openapi]
version = "0.11"
default-features = false

[dev-dependencies.k8s-openapi]
version = "0.11"
default-features = false
features = ["v1_20"]

[dev-dependencies]
kube-derive = "0.55"
schemars = "0.8"
Expand Down

0 comments on commit 7c0f26f

Please sign in to comment.