mirror of
https://github.com/dredx/prole.git
synced 2026-09-23 12:03:59 +00:00
- In k3s mode, resolve CNPG images to a cluster-reachable internal registry and ignore k3d/localhost-ish registry values. - Avoid any k3d cluster/containerd interactions when PROLE_MODE=k3s; add a preflight-image action. - Extend init scripts and Ansible k3s/mariadb import tasks/playbooks for the updated k3s flow. - Add/extend installer UI + tests around services and action/milestone helpers. - Add merlin MariaDB provisioning playbook, services init-script test, and a k3s datastore SQL snapshot. Co-authored-by: Junie <junie@jetbrains.com>
31 lines
935 B
YAML
31 lines
935 B
YAML
---
|
|
# Import local Docker image tarballs directly into k3s containerd on all nodes.
|
|
#
|
|
# Usage:
|
|
# ansible-playbook k3s_import_images.yml \
|
|
# -e '{"k3s_import_image_tars": ["/path/to/image1.tar", "/path/to/image2.tar"]}'
|
|
#
|
|
# This avoids the slow docker-push-to-registry flow by copying tarballs
|
|
# directly to each k3s node and importing via `k3s ctr images import`.
|
|
|
|
- name: Import container images into k3s nodes
|
|
hosts: k3s_hosts
|
|
gather_facts: false
|
|
become: true
|
|
serial: 1
|
|
pre_tasks:
|
|
- name: Gather minimal facts
|
|
ansible.builtin.setup:
|
|
gather_subset:
|
|
- min
|
|
|
|
- name: Skip import on hosts where k3s is disabled
|
|
ansible.builtin.meta: end_host
|
|
when: not (k3s_enabled | default(true) | bool)
|
|
tasks:
|
|
- name: Import image tarballs
|
|
ansible.builtin.import_role:
|
|
name: k3s
|
|
tasks_from: import_images
|
|
when: (k3s_import_images | default([])) | length > 0
|