mirror of
https://github.com/batonogov/learn-devops.git
synced 2025-11-29 16:53:01 +00:00
Add kubeadm example (#4)
* Add kubeadm example * Fix dns --------- Co-authored-by: Fedor Batonogov <f.batonogov@yandex.ru>
This commit is contained in:
committed by
GitHub
parent
346360f820
commit
07fb0c68bf
40
ansible/roles/haproxy_static_pods/tasks/main.yml
Normal file
40
ansible/roles/haproxy_static_pods/tasks/main.yml
Normal file
@@ -0,0 +1,40 @@
|
||||
# tasks file for haproxy_static_pods
|
||||
- name: Создать директории /etc/kubernetes/manifests и /etc/keepalived
|
||||
ansible.builtin.file:
|
||||
path: '{{ item }}'
|
||||
state: directory
|
||||
mode: '755'
|
||||
with_items:
|
||||
- /etc/kubernetes/manifests
|
||||
- /etc/keepalived
|
||||
- /etc/haproxy
|
||||
|
||||
- name: Наливаю конфигурацию keepalived
|
||||
ansible.builtin.template:
|
||||
src: keepalived.conf.j2
|
||||
dest: /etc/keepalived/keepalived.conf
|
||||
mode: "644"
|
||||
|
||||
- name: Наливаю check_apiserver.sh
|
||||
ansible.builtin.copy:
|
||||
src: check_apiserver.sh
|
||||
dest: /etc/keepalived/check_apiserver.sh
|
||||
mode: '644'
|
||||
|
||||
- name: Наливаю haproxy.cfg
|
||||
ansible.builtin.copy:
|
||||
src: haproxy.cfg
|
||||
dest: /etc/haproxy/haproxy.cfg
|
||||
mode: '644'
|
||||
|
||||
- name: Наливаю keepalived static pods manifest
|
||||
ansible.builtin.copy:
|
||||
src: keepalived.yaml
|
||||
dest: /etc/kubernetes/manifests/keepalived.yaml
|
||||
mode: '644'
|
||||
|
||||
- name: Наливаю haproxy static pods manifest
|
||||
ansible.builtin.copy:
|
||||
src: haproxy.yaml
|
||||
dest: /etc/kubernetes/manifests/haproxy.yaml
|
||||
mode: '644'
|
||||
Reference in New Issue
Block a user