Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enhance k3s_agent role to support conditional snapshotter for PXE-boo…
…ted systems. **Added:** - PXE Boot Check - Introduced tasks to check if the system is PXE-booted by analyzing `/proc/cmdline` in `roles/k3s_agent/tasks/main.yml`. - Conditional Snapshotter in Template - Added logic in `k3s.service.j2` template to conditionally set `--snapshotter native` for PXE-booted systems. **Changed:** - `k3s.service.j2` Template Update - Modified the `ExecStart` line to include a conditional check for `is_pxe_booted` fact, dynamically setting the `--snapshotter` option for NFS-mounted systems. - `main.yml` Task Modification - Added tasks to set `is_pxe_booted` fact based on the presence of `root=/dev/nfs` in the system's boot command line. This update allows k3s agents on PXE-booted systems to use the native snapshotter when running on NFS, addressing compatibility issues with OverlayFS.
- Loading branch information