Increase disksize;Add container image import during firstboot
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
40489ff373
commit
0c01f024e9
@ -16,3 +16,46 @@
|
||||
until: api_readycheck.apiVersion is defined
|
||||
retries: 3
|
||||
delay: 30
|
||||
|
||||
- block:
|
||||
|
||||
- name: Initialize tempfile
|
||||
ansible.builtin.tempfile:
|
||||
state: file
|
||||
register: kubeconfig
|
||||
|
||||
- name: Retrieve kubeconfig
|
||||
ansible.builtin.command:
|
||||
cmd: kubectl config view --raw
|
||||
register: kubectl_config
|
||||
|
||||
- name: Store kubeconfig in tempfile
|
||||
ansible.builtin.copy:
|
||||
dest: "{{ kubeconfig.path }}"
|
||||
content: "{{ kubectl_config.stdout }}"
|
||||
mode: 0600
|
||||
no_log: true
|
||||
|
||||
- block:
|
||||
|
||||
- name: Extract container images
|
||||
ansible.builtin.unarchive:
|
||||
src: /opt/metacluster/container_images/images-tarballs.tgz
|
||||
dest: /opt/metacluster/container_images
|
||||
list_files: yes
|
||||
register: imagetarballs
|
||||
|
||||
- ansible.builtin.debug:
|
||||
var: imagetarballs
|
||||
|
||||
- name: Import container images
|
||||
ansible.builtin.command:
|
||||
cmd: k3s ctr image import {{ item }}
|
||||
chdir: /opt/metacluster/container_images
|
||||
loop: "{{ imagetarballs.stdout_lines }}"
|
||||
|
||||
- name: Delete redundant files
|
||||
ansible.builtin.file:
|
||||
path: /opt/metacluster/container_images
|
||||
state: absent
|
||||
|
||||
|
@ -41,7 +41,7 @@ source "vsphere-iso" "k8sbootstrap" {
|
||||
network_card = "vmxnet3"
|
||||
}
|
||||
storage {
|
||||
disk_size = 20480
|
||||
disk_size = 51200
|
||||
disk_thin_provisioned = true
|
||||
}
|
||||
disk_controller_type = ["pvscsi"]
|
||||
|
Loading…
Reference in New Issue
Block a user