
This reverts commit
0d16bee11b
.
It is being reverted as the centos stream images
contain extra, un-necessary libraries and packages
installed which swells the ramdisk size up substantially
and is causing failures in CI as the compressed image size
expanded by about 100MB, and uncompressed the stream images
are 1.1GB.
Change-Id: I71eed30c27c109ac03d41e6ec46067148eb9b007
52 lines
1.6 KiB
YAML
52 lines
1.6 KiB
YAML
- name: Default to CentOS 8
|
|
set_fact:
|
|
image_release: 8
|
|
when:
|
|
- image_distro in ["centos-minimal", "centos"]
|
|
- not image_release
|
|
|
|
- name: Generate a nice target name for CentOS
|
|
set_fact:
|
|
image_target_name: centos{{ image_release }}
|
|
when:
|
|
- image_distro in ["centos-minimal", "centos"]
|
|
- not image_target_name
|
|
|
|
- name: Generate image name
|
|
set_fact:
|
|
image_name: ipa-{{ image_target_name | default(image_distro, true) }}-{{ ipa_branch_path }}
|
|
|
|
- name: Build a DIB image
|
|
command: |
|
|
ironic-python-agent-builder -o {{ image_name }} -b HEAD -v
|
|
{{ "-r {}".format(image_release) if image_release else '' }}
|
|
{% for element in extra_elements %}
|
|
--element {{ element }}
|
|
{% endfor %}
|
|
{{ "--extra-args '{}'".format(dib_extra_args) if dib_extra_args else '' }}
|
|
{{ image_distro }}
|
|
environment:
|
|
# Increase from the default value of 30
|
|
DIB_DHCP_TIMEOUT: 60
|
|
# Use repositories checked out by Zuul (combined with -b HEAD above)
|
|
DIB_REPOLOCATION_ironic_python_agent: '{{ ipa_source_path }}'
|
|
DIB_REPOLOCATION_requirements: '{{ requirements_path }}'
|
|
|
|
- name: Move the resulting files
|
|
shell: |
|
|
tar -czf "{{ ipa_tar_dir }}/{{ image_name }}.tar.gz" {{ image_name }}*
|
|
mv {{ image_name }}* "{{ ipa_raw_dir }}"
|
|
|
|
- name: Generate image checksums
|
|
shell:
|
|
cmd: sha256sum "{{ image_name }}.{{ item }}" > "{{ image_name }}.{{ item }}.sha256"
|
|
chdir: "{{ ipa_raw_dir }}"
|
|
with_items:
|
|
- kernel
|
|
- initramfs
|
|
|
|
- name: Generate tarball checksum
|
|
shell:
|
|
cmd: sha256sum "{{ image_name }}.tar.gz" > "{{ image_name }}.tar.gz.sha256"
|
|
chdir: "{{ ipa_tar_dir }}"
|