From e1a9137650f0931cc7ea5d387eae41e511641c92 Mon Sep 17 00:00:00 2001 From: Drew Walters Date: Fri, 23 Oct 2020 14:23:04 +0000 Subject: [PATCH] Update Kustomize config commands A recent refactor of the Kustomize config command [0] changed the config subcommand to cfg. Since airshipctl has introduced a version of Kustomize with the new subcommand, cfg, Treasuremap jobs are failing because they still use Kustomize config. This change updates kustomize config commands to kustomize cfg. [0] https://github.com/kubernetes-sigs/kustomize/commit/701c2177911a7f910e9841c4e0f4dd30c329c774#diff-73e268a15f17741962365907345f2ea7b20d8e2d19ec57efacb6067281b19b68 Change-Id: I9eaac604c9eafdb6791e49716ea109906ddfe9f6 --- playbooks/get-vm-config.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/playbooks/get-vm-config.yaml b/playbooks/get-vm-config.yaml index 7bbcabd87..79a4d26b3 100644 --- a/playbooks/get-vm-config.yaml +++ b/playbooks/get-vm-config.yaml @@ -10,12 +10,15 @@ # See the License for the specific language governing permissions and # limitations under the License. +# TODO(drewwalters96): Move this logic to an airshipctl role so breaking changes +# do not impact Treasuremap. + - name: get BareMetalHost objects shell: | set -e kustomize build --enable_alpha_plugins \ {{ airship_config_manifest_directory }}/{{ airship_config_site_path }}/{{ path }} | - kustomize config grep "kind=BareMetalHost" + kustomize cfg grep "kind=BareMetalHost" register: bmh_command failed_when: "bmh_command.stdout == ''" environment: @@ -30,7 +33,7 @@ set -e kustomize build --enable_alpha_plugins \ {{ airship_config_manifest_directory }}/{{ airship_config_site_path }}/{{ path }} | - kustomize config grep "metadata.name={{ item.spec.networkData.name }}" + kustomize cfg grep "metadata.name={{ item.spec.networkData.name }}" register: netdata_command failed_when: "netdata_command.stdout == ''" environment: