diff --git a/src/clients.rs b/src/clients.rs index 52c1b99..d199e13 100644 --- a/src/clients.rs +++ b/src/clients.rs @@ -107,12 +107,12 @@ pub async fn kube_resource_for( let name = kube_object.name_any(); - kube::discovery::pinned_kind(&client, &gvk) + kube::discovery::pinned_kind(client, &gvk) .await .with_context(|| { format!( "could not find resource type {:?} on cluster", - kube_object.types.clone().unwrap_or(TypeMeta::default()) + kube_object.types.clone().unwrap_or_default() ) }) } @@ -124,7 +124,7 @@ pub async fn kube_api_for( ) -> Result> { let ns = kube_object.metadata.namespace.as_deref(); - let (resource, caps) = kube_resource_for(&kube_object, &client).await?; + let (resource, caps) = kube_resource_for(kube_object, &client).await?; if caps.scope == kube::discovery::Scope::Cluster { Ok(kube::Api::all_with(client, &resource)) diff --git a/src/cluster_setup/mod.rs b/src/cluster_setup/mod.rs index 33187d0..18f72fc 100644 --- a/src/cluster_setup/mod.rs +++ b/src/cluster_setup/mod.rs @@ -141,7 +141,7 @@ async fn apply_manifest_yaml(client: kube::Client, manifest: &str) -> Result<()> let pp = PatchParams::apply("beavercds").force(); // this manifest has multiple documents (crds, deployment) - for yaml in multidoc_deserialize(&manifest)? { + for yaml in multidoc_deserialize(manifest)? { let obj: DynamicObject = serde_yml::from_value(yaml)?; debug!( "applying resource {} {}",