mirror of
https://github.com/techno-tim/k3s-ansible.git
synced 2026-09-16 17:13:19 +02:00
Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 68f6ea3ac1 | |||
| 32928332a9 | |||
| 2a7599f6a5 | |||
| af32ca77cf |
@@ -1,4 +1,24 @@
|
|||||||
---
|
---
|
||||||
|
- name: Manage K3s HTTP Proxy Configuration
|
||||||
|
when: proxy_env is defined
|
||||||
|
block:
|
||||||
|
- name: Create k3s.service.d directory
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: '{{ systemd_dir }}/k3s.service.d'
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
state: directory
|
||||||
|
mode: '0755'
|
||||||
|
|
||||||
|
|
||||||
|
- name: Deploy the K3s http_proxy configuration file
|
||||||
|
ansible.builtin.template:
|
||||||
|
src: "http_proxy.conf.j2"
|
||||||
|
dest: "{{ systemd_dir }}/k3s.service.d/http_proxy.conf"
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
mode: '0755'
|
||||||
|
|
||||||
- name: Create k3s-node.service.d directory
|
- name: Create k3s-node.service.d directory
|
||||||
file:
|
file:
|
||||||
path: '{{ systemd_dir }}/k3s-node.service.d'
|
path: '{{ systemd_dir }}/k3s-node.service.d'
|
||||||
@@ -6,7 +26,7 @@
|
|||||||
owner: root
|
owner: root
|
||||||
group: root
|
group: root
|
||||||
mode: '0755'
|
mode: '0755'
|
||||||
when: proxy_env is defined
|
|
||||||
|
|
||||||
- name: Copy K3s http_proxy conf file
|
- name: Copy K3s http_proxy conf file
|
||||||
template:
|
template:
|
||||||
@@ -15,4 +35,3 @@
|
|||||||
owner: root
|
owner: root
|
||||||
group: root
|
group: root
|
||||||
mode: '0755'
|
mode: '0755'
|
||||||
when: proxy_env is defined
|
|
||||||
|
|||||||
@@ -16,10 +16,6 @@
|
|||||||
- name: Include http_proxy configuration tasks
|
- name: Include http_proxy configuration tasks
|
||||||
ansible.builtin.include_tasks: http_proxy.yml
|
ansible.builtin.include_tasks: http_proxy.yml
|
||||||
|
|
||||||
- name: Deploy K3s http_proxy conf
|
|
||||||
include_tasks: http_proxy.yml
|
|
||||||
when: proxy_env is defined
|
|
||||||
|
|
||||||
- name: Configure the k3s service
|
- name: Configure the k3s service
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "k3s.service.j2"
|
src: "k3s.service.j2"
|
||||||
|
|||||||
Reference in New Issue
Block a user