bodsch / ansible-k0s Goto Github PK
View Code? Open in Web Editor NEWInstall and configure a kubernetes cluster using ansible and the vanilla upstream Kubernetes distro k0s.
Install and configure a kubernetes cluster using ansible and the vanilla upstream Kubernetes distro k0s.
When running your k0s role, the playbook runs into an error, that I am not able to debug.
Could you please take a look at it, I'm not sure why this error is happening or how to debug it properly.
ansible [core 2.13.4]
config file = /home/kevin/workspace/adit/awx/ansible/ansible.cfg
configured module search path = ['/home/kevin/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /home/kevin/workspace/adit/awx/venv/lib/python3.10/site-packages/ansible
ansible collection location = /home/kevin/.ansible/collections:/usr/share/ansible/collections
executable location = /home/kevin/workspace/adit/awx/venv/bin/ansible
python version = 3.10.4 (main, Jun 29 2022, 12:14:53) [GCC 11.2.0]
jinja version = 3.1.2
libyaml = True
---
- hosts: all
roles:
- k0s
ansible_user: debian
k0s_cluster_nodes:
initial_controller: "controller1"
controllers: ["controller2", "controller3"]
workers: ["worker1"]
The role completes all necessary steps and sets up a complete cluster with k0s
The cluster is created, but only with the initial_controller, the other controllers fail with the following error:
TASK [k0s : create k0s controller service with install command] ********************************************************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType
fatal: [controller3]: FAILED! => {"changed": false, "module_stderr": "Shared connection to 10.40.131.234 closed.\r\n", "module_stdout": "Traceback (most recent call last):\r\n File \"/home/debian/.ansible/tmp/ansible-tmp-1663931311.561756-27647-148094266551000/AnsiballZ_k0s_install.py\", line 107, in <module>\r\n _ansiballz_main()\r\n File \"/home/debian/.ansible/tmp/ansible-tmp-1663931311.561756-27647-148094266551000/AnsiballZ_k0s_install.py\", line 99, in _ansiballz_main\r\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\r\n File \"/home/debian/.ansible/tmp/ansible-tmp-1663931311.561756-27647-148094266551000/AnsiballZ_k0s_install.py\", line 47, in invoke_module\r\n runpy.run_module(mod_name='ansible.modules.k0s_install', init_globals=dict(_module_fqn='ansible.modules.k0s_install', _modlib_path=modlib_path),\r\n File \"/usr/lib/python3.9/runpy.py\", line 210, in run_module\r\n return _run_module_code(code, init_globals, run_name, mod_spec)\r\n File \"/usr/lib/python3.9/runpy.py\", line 97, in _run_module_code\r\n _run_code(code, mod_globals, init_globals,\r\n File \"/usr/lib/python3.9/runpy.py\", line 87, in _run_code\r\n exec(code, run_globals)\r\n File \"/tmp/ansible_k0s_install_payload_1_3z3zsv/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 240, in <module>\r\n File \"/tmp/ansible_k0s_install_payload_1_3z3zsv/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 231, in main\r\n File \"/tmp/ansible_k0s_install_payload_1_3z3zsv/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 59, in run\r\n File \"/tmp/ansible_k0s_install_payload_1_3z3zsv/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 79, in k0s_install\r\n File \"/usr/lib/python3.9/genericpath.py\", line 30, in isfile\r\n st = os.stat(path)\r\nTypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType\r\n", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType
fatal: [controller2]: FAILED! => {"changed": false, "module_stderr": "Shared connection to 10.40.131.89 closed.\r\n", "module_stdout": "Traceback (most recent call last):\r\n File \"/home/debian/.ansible/tmp/ansible-tmp-1663931311.5873406-27649-115115981473066/AnsiballZ_k0s_install.py\", line 107, in <module>\r\n _ansiballz_main()\r\n File \"/home/debian/.ansible/tmp/ansible-tmp-1663931311.5873406-27649-115115981473066/AnsiballZ_k0s_install.py\", line 99, in _ansiballz_main\r\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\r\n File \"/home/debian/.ansible/tmp/ansible-tmp-1663931311.5873406-27649-115115981473066/AnsiballZ_k0s_install.py\", line 47, in invoke_module\r\n runpy.run_module(mod_name='ansible.modules.k0s_install', init_globals=dict(_module_fqn='ansible.modules.k0s_install', _modlib_path=modlib_path),\r\n File \"/usr/lib/python3.9/runpy.py\", line 210, in run_module\r\n return _run_module_code(code, init_globals, run_name, mod_spec)\r\n File \"/usr/lib/python3.9/runpy.py\", line 97, in _run_module_code\r\n _run_code(code, mod_globals, init_globals,\r\n File \"/usr/lib/python3.9/runpy.py\", line 87, in _run_code\r\n exec(code, run_globals)\r\n File \"/tmp/ansible_k0s_install_payload_z0_svte8/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 240, in <module>\r\n File \"/tmp/ansible_k0s_install_payload_z0_svte8/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 231, in main\r\n File \"/tmp/ansible_k0s_install_payload_z0_svte8/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 59, in run\r\n File \"/tmp/ansible_k0s_install_payload_z0_svte8/ansible_k0s_install_payload.zip/ansible/modules/k0s_install.py\", line 79, in k0s_install\r\n File \"/usr/lib/python3.9/genericpath.py\", line 30, in isfile\r\n st = os.stat(path)\r\nTypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType\r\n", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.