mirror of
https://github.com/PyratLabs/ansible-role-k3s
synced 2024-11-09 23:13:30 +01:00
feat(systemd): added molecule tests for #164
This commit is contained in:
parent
0c77eb143d
commit
ccfa561be0
3 changed files with 9 additions and 0 deletions
|
@ -18,5 +18,7 @@
|
|||
k3s_server_manifests_urls:
|
||||
- url: https://raw.githubusercontent.com/metallb/metallb/v0.9.6/manifests/namespace.yaml
|
||||
filename: 05-metallb-namespace.yml
|
||||
k3s_service_env_vars:
|
||||
GOGC: 10
|
||||
roles:
|
||||
- role: "{{ lookup('env', 'MOLECULE_PROJECT_DIRECTORY') | basename }}"
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
datastore-endpoint: "postgres://postgres:verybadpass@database:5432/postgres?sslmode=disable"
|
||||
k3s_agent:
|
||||
snapshotter: native
|
||||
k3s_service_env_file: /tmp/k3s.env
|
||||
pre_tasks:
|
||||
- name: Set each node to be a control node
|
||||
ansible.builtin.set_fact:
|
||||
|
|
|
@ -37,3 +37,9 @@
|
|||
ansible.builtin.apt:
|
||||
update_cache: true
|
||||
when: ansible_pkg_mgr == 'apt'
|
||||
|
||||
- name: Ensure environment file exists for k3s_service_env_file
|
||||
ansible.builtin.lineinfile:
|
||||
path: /tmp/k3s.env
|
||||
line: "THISHOST={{ ansible_hostname }}"
|
||||
mode: 0644
|
||||
|
|
Loading…
Reference in a new issue