Skip to content

Commit

Permalink
Fixing error when bootstraping the cluster with new prometheus-crd-ch…
Browse files Browse the repository at this point in the history
…art: using --enable-helm kustomize flag
  • Loading branch information
ricsanfre committed Nov 18, 2023
1 parent 0587624 commit 410f12f
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions ansible/k3s_bootstrap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
- name: Bootstrap Cluster
hosts: node1
gather_facts: false
become: false

collections:
- kubernetes.core
Expand Down Expand Up @@ -35,10 +36,10 @@
become: true

# Install Helm diff plugin to have a better idempotence check
- name: Intall Helm Plugin
kubernetes.core.helm_plugin:
plugin_path: "https://github.com/databus23/helm-diff"
state: present
# - name: Intall Helm Plugin
# kubernetes.core.helm_plugin:
# plugin_path: "https://github.com/databus23/helm-diff"
# state: present

- name: Include vault variables
include_vars: "vars/vault.yml"
Expand Down Expand Up @@ -69,8 +70,12 @@
- "bootstrap/argocd"

- name: Install CRDs
ansible.builtin.command:
cmd: kubectl apply --server-side --kustomize /tmp/charts/crds
ansible.builtin.shell: |
set -o pipefail
kubectl kustomize /tmp/charts/crds --enable-helm \
| kubectl apply --server-side -f -
args:
executable: /bin/bash

- name: Update argo-cd helm dependency.
ansible.builtin.command:
Expand Down

0 comments on commit 410f12f

Please sign in to comment.