feat(offline): Improve generate_list.sh to generate offline file list using ansible (#8537) (#8538)

Use jinja2 template and ansible to expand variables.
This commit is contained in:
Takuya Murakami
2022-02-14 16:19:28 +09:00
committed by GitHub
parent da8522af64
commit b02e68222f
3 changed files with 41 additions and 47 deletions

View File

@@ -0,0 +1,19 @@
---
- hosts: localhost
become: no
roles:
# Just load default variables from roles.
- role: kubespray-defaults
when: false
- role: download
when: false
tasks:
# Generate files.list and images.list files from templates.
- template:
src: ./contrib/offline/temp/{{ item }}.list.template
dest: ./contrib/offline/temp/{{ item }}.list
with_items:
- files
- images