Page MenuHomePhorge

No OneTemporary

Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
diff --git a/deployments/ansible/roles/kolab/tasks/main.yaml b/deployments/ansible/roles/kolab/tasks/main.yaml
index 5a6cfbb..3cb6df0 100644
--- a/deployments/ansible/roles/kolab/tasks/main.yaml
+++ b/deployments/ansible/roles/kolab/tasks/main.yaml
@@ -1,30 +1,34 @@
---
- ansible.builtin.shell: |
sed -i "s/127.0.0.1/{{ kubernetes_ip }}/" {{ kubeconfig }}; \
env KUBECONFIG={{ kubeconfig }} kubectl config set-context --namespace=kolab --user=default --cluster=default --current; \
- name: Check kubectl config
ansible.builtin.shell:
cmd: env KUBECONFIG={{ kubeconfig }} kubectl get pods
- name: Apply primary node label
ansible.builtin.shell:
cmd: env KUBECONFIG={{ kubeconfig }} kubectl label nodes {{ hostvars[groups['worker_nodes'][0]].inventory_hostname }} kolab.org/nodegroup=primary
when: label_nodes | bool
- name: Apply secondary node label
ansible.builtin.shell:
cmd: env KUBECONFIG={{ kubeconfig }} kubectl label nodes {{ hostvars[groups['worker_nodes'][1]].inventory_hostname }} kolab.org/nodegroup=secondary
when: label_nodes | bool
- name: Prepare k3s
ansible.builtin.shell:
cmd: env DISABLE_CERT_MANAGER={{ disable_cert_manager|bool|lower }} DISABLE_INGRESS={{ disable_ingress|bool|lower }} KUBECONFIG={{ kubeconfig }} {{ kolabctl_path }} k3s-setup
ignore_errors: true
- ansible.builtin.set_fact:
registry_env: "IMAGE_REGISTRY={{ primary_ip }}:5001 IMAGE_VERSION=latest"
when: local_registry | bool
- ansible.builtin.shell:
cmd: env {{ registry_env | default("") }} {{reconfigure_env}} {{ kolabctl_path }} reconfigure
chdir: "{{ resources_dir }}"
- when: not skip_reconfigure | bool
+ when:
+ - not skip_reconfigure | bool
+ - not production
- name: "Deploying kolab"
ansible.builtin.shell:
cmd: env KUBECONFIG={{ kubeconfig }} CHART_URL={{ chart_url }} {{ kolabctl_path }} apply --force
chdir: "{{ resources_dir }}"
+ when:
+ - not production

File Metadata

Mime Type
text/x-diff
Expires
Sat, Apr 4, 9:50 AM (3 w, 5 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18823545
Default Alt Text
(1 KB)

Event Timeline