aboutsummaryrefslogtreecommitdiffstats
path: root/kud/deployment_infra/playbooks/configure-kud.yml
blob: 0e32e69d34f88fb4cc9b1e1e4377af6cb085eb14 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
---
# SPDX-license-identifier: Apache-2.0
##############################################################################
# Copyright (c) 2018
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
# which accompanies this distribution, and is available at
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
- hosts: localhost
  pre_tasks:
    - name: Load kud variables
      include_vars:
        file: kud-vars.yml
    - name: Check if helm client is already installed #It is in single node deployment
      command: helm version -c
      register: helm_client
      failed_when: False
      changed_when: False
      check_mode: False
  roles:
    - name: andrewrothstein.kubernetes-helm
      when: helm_client.rc != 0
      vars:
          kubernetes_helm_ver: "v{{ helm_client_version }}"

- hosts: kube-node
  become: yes
  tasks:
    - name: copy admin.conf file to kube-nodes
      copy:
        src: "{{ lookup('env','kud_inventory_folder') }}/artifacts/admin.conf"
        dest: "/etc/kubernetes/admin.conf"