From 665ad3454b43b17a695531adc691e9bfd193bcc9 Mon Sep 17 00:00:00 2001 From: gonzalezzfelipe Date: Thu, 7 Nov 2024 18:59:52 -0300 Subject: [PATCH 1/2] fix: Add workflow dispatch triggers --- .github/workflows/docker.yml | 1 + .github/workflows/hydra.yml | 5 +---- .github/workflows/init.yml | 5 +---- 3 files changed, 3 insertions(+), 8 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index dbcdc0f..8376bef 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -1,5 +1,6 @@ name: Docker on: + workflow_dispatch: {} push: branches: - "main" diff --git a/.github/workflows/hydra.yml b/.github/workflows/hydra.yml index ec09785..5a21f4f 100644 --- a/.github/workflows/hydra.yml +++ b/.github/workflows/hydra.yml @@ -7,10 +7,7 @@ on: paths: - ".github/workflows/hydra.yml" - "docker/dockerfile.hydra" - workflow_dispatch: - inputs: - mumak_version: - required: false + workflow_dispatch: {} jobs: build-images: diff --git a/.github/workflows/init.yml b/.github/workflows/init.yml index 9155568..7d26b5f 100644 --- a/.github/workflows/init.yml +++ b/.github/workflows/init.yml @@ -7,10 +7,7 @@ on: paths: - ".github/workflows/init.yml" - "docker/dockerfile.init" - workflow_dispatch: - inputs: - mumak_version: - required: false + workflow_dispatch: {} jobs: build-images: From db2a6856bfb6d6aa09cb1d6fdfc017c4111cf9b9 Mon Sep 17 00:00:00 2001 From: gonzalezzfelipe Date: Thu, 7 Nov 2024 19:17:42 -0300 Subject: [PATCH 2/2] fix: Make operator namespaced --- src/bin/operator.rs | 2 +- src/controller.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/operator.rs b/src/bin/operator.rs index a268595..09a4b5a 100644 --- a/src/bin/operator.rs +++ b/src/bin/operator.rs @@ -23,7 +23,7 @@ async fn main() -> Result<()> { let context = Arc::new(K8sContext::new(client.clone(), config)); // Create controller for MyApp custom resource - let api: Api = Api::all(client); + let api: Api = Api::default_namespaced(client); info!("Running controller."); let controller = Controller::new(api, Default::default()) .run(reconcile, error_policy, context.clone()) diff --git a/src/controller.rs b/src/controller.rs index 4a100d1..0fcdf14 100644 --- a/src/controller.rs +++ b/src/controller.rs @@ -379,7 +379,7 @@ impl K8sContext { } async fn patch_statuses(&self) -> anyhow::Result<()> { - let api: Api = Api::all(self.client.clone()); + let api: Api = Api::default_namespaced(self.client.clone()); let crds = api.list(&ListParams::default()).await?; let mut awaitables = vec![];