Files
zuul-providers/zuul.d/image-build-jobs.yaml

619 lines
20 KiB
YAML

- job:
name: opendev-build-diskimage-base
description: |
The abstract base job for building VM images used in OpenDev's Zuul
If the variable ``image_upload_secret`` is provided (as a
secret) this job will upload the resulting image (this should be
done in image build pipelines). Otherwise, it will only build
the image without uploading it (this can be useful for check
pipelines).
parent: build-diskimage
timeout: 10800
post-timeout: 10800
abstract: true
# This causes us to run DIB from the git repo instead of the
# latest release.
required-projects:
- openstack/diskimage-builder
# Temporarily fix the image build jobs to run on the nodepool
# label without using nodesets so that we can change the nodeset
# definitions without triggering image rebuilds during the
# transition.
nodeset:
nodes:
- name: ubuntu-noble
label: ubuntu-noble
pre-run:
- playbooks/opendev-build-diskimage-base/pre.yaml
post-run:
- playbooks/opendev-build-diskimage-base/post.yaml
files:
- 'dib-elements/.*'
- 'playbooks/opendev-build-diskimage-base/.*'
- 'roles/make-source-repositories-cache/.*'
vars:
# The format list is intentionally sorted. DIB makes raw always
# run last. VHD has an intermediate stage where it contains two
# full copies of the image. To try to save space to have room
# for that, we want to run vhd before qcow2, so we reverse sort.
build_diskimage_formats: "{{ zuul.image_formats | default(['qcow2', 'raw', 'vhd']) | sort(reverse=true) }}"
# /opt/dib_tmp is an ephemeral disk if present
build_diskimage_image_root: "/opt/dib_tmp/dib-images"
build_diskimage_elements: &base_elements
- vm
- simple-init
- openstack-repos
- nodepool-base
- growroot
- infra-package-needs
- cache-devstack
- delete-cache
build_diskimage_environment:
TMPDIR: /opt/dib_tmp
ELEMENTS_PATH: "{{ ansible_user_dir }}/{{ zuul.projects['opendev.org/opendev/zuul-providers'].src_dir }}/dib-elements"
# TODO: Do we want streaming logs?
DIB_QUIET: '0'
DIB_NO_TMPFS: '1'
DIB_CHECKSUM: '1'
DIB_IMAGE_CACHE: /opt/dib_cache
DIB_JOURNAL_SIZE: '512'
DIB_GRUB_TIMEOUT: '0'
GIT_HTTP_LOW_SPEED_TIME: '300'
GIT_HTTP_LOW_SPEED_LIMIT: '1000'
DIB_SHOW_IMAGE_USAGE: '1'
ZUUL_USER_SSH_PUBLIC_KEY: "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDh5u0DWNi0d3uqI82izAxVTUTrGl36L3szEqV9WrilGmxaTtp9X7HrktJ5J+rvxQqz39llTf1v7iYA4CNKto/48RBAB0mKEEI4x4iw+fu/BLU7nu7ewSfXLUxHahxaTgIk2KcbegknD5NzMjalyfNfgTPDGv8BjwHeeNdZmJMBvPFGu6fO48M4yK1tiQn0kAkaH4oII/M4pyF8vy9tPTODAD7RvnMvQAb08LZZvE/IPzJAHNXFRb1v+DBa38fOvdyaz/nibrsxiOWZxQVLgjYciUeDy1xvXADaWlqvxmLy+90LHbJFbGxK4AN0mWfwBiUMVyxZjkun39pjTNl2k09OhOq+R52UqnehMc4eBdZCddnCUq4/efbFCJkqe5wY+SE8fYybJjauUL64zyrwf6yfWkXvPVHWa9Y+NCmvH8PCBUcsQnwO7l/Yb4N+8+u6zkODyuc9wLAY+DpnptE3plXtvUs5negC4fvJSnOHpWXuoi9yzp7IlPf6fSjMMDQo0JjCYJwazdzqrIH2VSCcfHAqWF0ECR8IgwZV1bp0xFe0UN0Gjsgkozqf8rvs1AYyTSeD19Wg9j+crTke8E1sfoI/qFzHwzBQFKJ+2l0cs7pZWJBARlhbt1j1IouS2aH+74xwsavRhBz4IsFTPqWiP6JTrgk5cgKRnTqInzNfdaLeUw== zuul-worker@openstack.org"
- job:
name: opendev-dispatch-promote-diskimage
description: |
Decide which diskimage promotion jobs should run
run: playbooks/opendev-promote-diskimage/dispatch.yaml
nodeset:
nodes: []
vars:
promote_artifact_api: "https://zuul.opendev.org/api/tenant/{{ zuul.tenant }}"
promote_artifact_pipeline: gate
build_artifact_job: "{{ child_job | regex_replace('^opendev-promote', 'opendev-build') }}"
- job:
name: opendev-promote-diskimage-base
description: |
Promote diskimage gate builds to production
abstract: true
run: playbooks/opendev-promote-diskimage/run.yaml
nodeset:
nodes: []
vars:
promote_artifact_api: "https://zuul.opendev.org/api/tenant/{{ zuul.tenant }}"
promote_artifact_pipeline: gate
promote_artifact_type: zuul_image
promote_artifact_job: "{{ zuul.job | regex_replace('^opendev-promote', 'opendev-build') }}"
dependencies:
- opendev-dispatch-promote-diskimage
- job:
name: opendev-build-diskimage-base-debuntu
description: |
An abstract base job for building Debian or Ubuntu based VM images
parent: opendev-build-diskimage-base
abstract: true
vars:
build_diskimage_environment:
DIB_APT_LOCAL_CACHE: '0'
DIB_DISABLE_APT_CLEANUP: '1'
DIB_DEBOOTSTRAP_EXTRA_ARGS: '--no-check-gpg'
- job:
name: opendev-build-diskimage-base-el
description: |
An abstract base job for building CentOS/Rocky/clones based VM images
parent: opendev-build-diskimage-base
abstract: true
vars:
build_diskimage_environment:
DIB_EPEL_DISABLED: '1'
- job:
name: opendev-build-diskimage-almalinux-10
description: |
Build the OpenDev Alma Linux 10 VM image
parent: opendev-build-diskimage-base-el
image-build-name: almalinux-10
vars:
build_diskimage_image_name: almalinux-10
build_diskimage_elements:
- *base_elements
- almalinux-container
- epel
build_diskimage_environment:
DIB_CONTAINERFILE_BUILDOPTS: "--platform linux/amd64/v2"
DIB_RELEASE: '10'
- job:
name: opendev-promote-diskimage-almalinux-10
parent: opendev-promote-diskimage-base
image-build-name: almalinux-10
- job:
name: opendev-build-diskimage-almalinux-10-arm64
description: |
Build the OpenDev Alma Linux 10 arm64 VM image
parent: opendev-build-diskimage-base-el
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: almalinux-10-arm64
vars:
build_diskimage_formats: ['raw']
build_diskimage_image_name: almalinux-10-arm64
build_diskimage_elements:
- *base_elements
- almalinux-container
- epel
build_diskimage_environment:
DIB_RELEASE: '10'
- job:
name: opendev-promote-diskimage-almalinux-10-arm64
parent: opendev-promote-diskimage-base
image-build-name: almalinux-10-arm64
- job:
name: opendev-build-diskimage-centos-9-stream
description: |
Build the OpenDev CentOS 9 Stream VM image
parent: opendev-build-diskimage-base-el
image-build-name: centos-9-stream
vars:
build_diskimage_elements:
- *base_elements
- centos-minimal
- epel
build_diskimage_environment:
DIB_RELEASE: '9-stream'
- job:
name: opendev-promote-diskimage-centos-9-stream
parent: opendev-promote-diskimage-base
image-build-name: centos-9-stream
- job:
name: opendev-build-diskimage-centos-9-stream-arm64
description: |
Build the OpenDev CentOS 9 Stream arm64 VM image
parent: opendev-build-diskimage-centos-9-stream
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: centos-9-stream-arm64
vars:
build_diskimage_formats: ['raw']
- job:
name: opendev-promote-diskimage-centos-9-stream-arm64
parent: opendev-promote-diskimage-base
image-build-name: centos-9-stream-arm64
#NOTE: using nested virt nodes to ensure EL10 hw support
- job:
name: opendev-build-diskimage-centos-10-stream
description: |
Build the OpenDev CentOS 10 Stream VM image
nodeset:
nodes:
- name: nested-virt-ubuntu-noble
label: nested-virt-ubuntu-noble
parent: opendev-build-diskimage-base-el
image-build-name: centos-10-stream
vars:
build_diskimage_elements:
- *base_elements
- centos-minimal
- epel
build_diskimage_environment:
DIB_RELEASE: '10-stream'
- job:
name: opendev-promote-diskimage-centos-10-stream
parent: opendev-promote-diskimage-base
image-build-name: centos-10-stream
- job:
name: opendev-build-diskimage-centos-10-stream-arm64
description: |
Build the OpenDev CentOS 10 Stream arm64 VM image
parent: opendev-build-diskimage-centos-10-stream
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: centos-10-stream-arm64
- job:
name: opendev-promote-diskimage-centos-10-stream-arm64
parent: opendev-promote-diskimage-base
image-build-name: centos-10-stream-arm64
vars:
build_diskimage_formats: ['raw']
- job:
name: opendev-build-diskimage-rockylinux-8
description: |
Build the OpenDev Rocky Linux 8 VM image
parent: opendev-build-diskimage-base-el
image-build-name: rockylinux-8
vars:
build_diskimage_elements:
- *base_elements
- rocky-container
- epel
build_diskimage_environment:
DIB_RELEASE: '8'
- job:
name: opendev-promote-diskimage-rockylinux-8
parent: opendev-promote-diskimage-base
image-build-name: rockylinux-8
- job:
name: opendev-build-diskimage-rockylinux-9
description: |
Build the OpenDev Rocky Linux 9 VM image
parent: opendev-build-diskimage-base-el
image-build-name: rockylinux-9
vars:
build_diskimage_elements:
- *base_elements
- rocky-container
- epel
build_diskimage_environment:
DIB_RELEASE: '9'
- job:
name: opendev-promote-diskimage-rockylinux-9
parent: opendev-promote-diskimage-base
image-build-name: rockylinux-9
- job:
name: opendev-build-diskimage-rockylinux-9-arm64
description: |
Build the OpenDev Rocky Linux 9 arm64 VM image
parent: opendev-build-diskimage-rockylinux-9
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: rockylinux-9-arm64
vars:
build_diskimage_formats: ['raw']
- job:
name: opendev-promote-diskimage-rockylinux-9-arm64
parent: opendev-promote-diskimage-base
image-build-name: rockylinux-9-arm64
#NOTE: using nested virt nodes to ensure EL10 hw support
- job:
name: opendev-build-diskimage-rockylinux-10
description: |
Build the OpenDev Rocky Linux 10 VM image
parent: opendev-build-diskimage-base-el
nodeset:
nodes:
- name: nested-virt-ubuntu-noble
label: nested-virt-ubuntu-noble
image-build-name: rockylinux-10
vars:
build_diskimage_elements:
- *base_elements
- rocky-container
- epel
build_diskimage_environment:
DIB_RELEASE: '10'
- job:
name: opendev-promote-diskimage-rockylinux-10
parent: opendev-promote-diskimage-base
image-build-name: rockylinux-10
- job:
name: opendev-build-diskimage-rockylinux-10-arm64
description: |
Build the OpenDev Rocky Linux 10 arm64 VM image
parent: opendev-build-diskimage-rockylinux-10
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: rockylinux-10-arm64
- job:
name: opendev-promote-diskimage-rockylinux-10-arm64
parent: opendev-promote-diskimage-base
image-build-name: rockylinux-10-arm64
vars:
build_diskimage_formats: ['raw']
- job:
name: opendev-build-diskimage-debian-bookworm
description: |
Build the OpenDev Debian Bookworm VM image
parent: opendev-build-diskimage-base-debuntu
image-build-name: debian-bookworm
vars:
build_diskimage_elements:
- *base_elements
- debian-minimal
build_diskimage_environment:
DIB_RELEASE: 'bookworm'
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/debian'
DIB_DEBIAN_SECURITY_MIRROR:
'https://{{ zuul_site_mirror_fqdn }}/debian-security'
- job:
name: opendev-promote-diskimage-debian-bookworm
parent: opendev-promote-diskimage-base
image-build-name: debian-bookworm
- job:
name: opendev-build-diskimage-debian-bookworm-arm64
description: |
Build the OpenDev Debian Bookworm arm64 VM image
parent: opendev-build-diskimage-debian-bookworm
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: debian-bookworm-arm64
- job:
name: opendev-promote-diskimage-debian-bookworm-arm64
parent: opendev-promote-diskimage-base
image-build-name: debian-bookworm-arm64
vars:
build_diskimage_formats: ['raw']
- job:
name: opendev-build-diskimage-debian-bullseye
description: |
Build the OpenDev Debian bullseye VM image
parent: opendev-build-diskimage-base-debuntu
image-build-name: debian-bullseye
vars:
build_diskimage_elements:
- *base_elements
- debian-minimal
build_diskimage_environment:
DIB_RELEASE: 'bullseye'
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/debian'
DIB_DEBIAN_SECURITY_MIRROR:
'https://{{ zuul_site_mirror_fqdn }}/debian-security'
- job:
name: opendev-promote-diskimage-debian-bullseye
parent: opendev-promote-diskimage-base
image-build-name: debian-bullseye
- job:
name: opendev-build-diskimage-debian-bullseye-arm64
description: |
Build the OpenDev Debian Bullseye arm64 VM image
parent: opendev-build-diskimage-debian-bullseye
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: debian-bullseye-arm64
vars:
build_diskimage_formats: ['raw']
- job:
name: opendev-promote-diskimage-debian-bullseye-arm64
parent: opendev-promote-diskimage-base
image-build-name: debian-bullseye-arm64
- job:
name: opendev-build-diskimage-debian-trixie
description: |
Build the OpenDev Debian Trixie VM image
parent: opendev-build-diskimage-base-debuntu
image-build-name: debian-trixie
vars:
build_diskimage_elements:
- *base_elements
- debian-minimal
- cache-devstack
build_diskimage_environment:
DIB_RELEASE: 'trixie'
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/debian'
DIB_DEBIAN_SECURITY_MIRROR:
'https://{{ zuul_site_mirror_fqdn }}/debian-security'
- job:
name: opendev-promote-diskimage-debian-trixie
parent: opendev-promote-diskimage-base
image-build-name: debian-trixie
- job:
name: opendev-build-diskimage-debian-trixie-arm64
description: |
Build the OpenDev Debian Trixie arm64 VM image
parent: opendev-build-diskimage-debian-trixie
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: debian-trixie-arm64
vars:
build_diskimage_formats: ['raw']
build_diskimage_image_name: debian-trixie-arm64
upload_image_swift_hash_timeout: 1200
- job:
name: opendev-promote-diskimage-debian-trixie-arm64
parent: opendev-promote-diskimage-base
image-build-name: debian-trixie-arm64
- job:
name: opendev-build-diskimage-ubuntu-focal
description: |
Build the OpenDev Ubuntu Focal VM image
parent: opendev-build-diskimage-base-debuntu
image-build-name: ubuntu-focal
vars:
build_diskimage_elements:
- *base_elements
- ubuntu-minimal
- cache-devstack
build_diskimage_environment:
DIB_RELEASE: 'focal'
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/ubuntu'
DIB_DEBIAN_COMPONENTS: 'main,universe'
- job:
name: opendev-promote-diskimage-ubuntu-focal
parent: opendev-promote-diskimage-base
image-build-name: ubuntu-focal
- job:
name: opendev-build-diskimage-ubuntu-focal-arm64
description: |
Build the OpenDev Ubuntu Focal arm64 VM image
parent: opendev-build-diskimage-ubuntu-focal
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: ubuntu-focal-arm64
vars:
build_diskimage_formats: ['raw']
build_diskimage_environment:
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/ubuntu-ports'
- job:
name: opendev-promote-diskimage-ubuntu-focal-arm64
parent: opendev-promote-diskimage-base
image-build-name: ubuntu-focal-arm64
- job:
name: opendev-build-diskimage-ubuntu-jammy
description: |
Build the OpenDev Ubuntu Jammy VM image
parent: opendev-build-diskimage-base-debuntu
image-build-name: ubuntu-jammy
vars:
build_diskimage_elements:
- *base_elements
- ubuntu-minimal
build_diskimage_environment:
DIB_RELEASE: 'jammy'
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/ubuntu'
DIB_DEBIAN_COMPONENTS: 'main,universe'
# NOTE(ianw) 2022-05-20 : we have found a problem on some cloud
# providers (OVH at least) where setting SSBD mitigation flags
# seems to be disabled and this causes endless kernel tracebacks
# from writing invalid flags into MSR registers, flooding the
# logs. By default spec_store_bypass_disable is set to
# "seccomp" which means the kernel forces every seccomp() call
# into this. Setting it to prctl means userspace has to opt-in
# with an explicit call. This is actually the default on more
# recent kernels; the reasons are many but the bug [1] goes
# through it with links to relevant changes.
#
# While we try and sort out either backporting this to upstream
# kernels or some other upstream workaround, we set
# spec_store_bypass_disable=prctl here to avoid this problem in
# our providers. The other bits are just the dib defaults which
# need to be replicated when overriding this.
#
# [1] https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1973839
DIB_BOOTLOADER_DEFAULT_CMDLINE: 'nofb nomodeset gfxpayload=text spec_store_bypass_disable=prctl'
- job:
name: opendev-promote-diskimage-ubuntu-jammy
parent: opendev-promote-diskimage-base
image-build-name: ubuntu-jammy
- job:
name: opendev-build-diskimage-ubuntu-jammy-arm64
description: |
Build the OpenDev Ubuntu Jammy arm64 VM image
parent: opendev-build-diskimage-ubuntu-jammy
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: ubuntu-jammy-arm64
vars:
build_diskimage_formats: ['raw']
build_diskimage_environment:
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/ubuntu-ports'
- job:
name: opendev-promote-diskimage-ubuntu-jammy-arm64
parent: opendev-promote-diskimage-base
image-build-name: ubuntu-jammy-arm64
- job:
name: opendev-build-diskimage-ubuntu-noble
description: |
Build the OpenDev Ubuntu Noble VM image
parent: opendev-build-diskimage-base-debuntu
image-build-name: ubuntu-noble
vars:
build_diskimage_elements:
- *base_elements
- ubuntu-minimal
build_diskimage_environment:
DIB_RELEASE: 'noble'
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/ubuntu'
DIB_DEBIAN_COMPONENTS: 'main,universe'
- job:
name: opendev-promote-diskimage-ubuntu-noble
parent: opendev-promote-diskimage-base
image-build-name: ubuntu-noble
- job:
name: opendev-build-diskimage-ubuntu-noble-arm64
description: |
Build the OpenDev Ubuntu Noble arm64 VM image
parent: opendev-build-diskimage-ubuntu-noble
nodeset:
nodes:
- name: ubuntu-noble-arm64
label: ubuntu-noble-arm64
image-build-name: ubuntu-noble-arm64
vars:
build_diskimage_formats: ['raw']
build_diskimage_environment:
DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/ubuntu-ports'
- job:
name: opendev-promote-diskimage-ubuntu-noble-arm64
parent: opendev-promote-diskimage-base
image-build-name: ubuntu-noble-arm64
- job:
name: opendev-build-diskimage-ubuntu-resolute
description: |
Build the OpenDev Ubuntu Resolute VM image
parent: opendev-build-diskimage-base-debuntu
image-build-name: ubuntu-resolute
vars:
build_diskimage_elements:
- *base_elements
- ubuntu-minimal
build_diskimage_environment:
DIB_RELEASE: 'resolute'
# DIB_DISTRIBUTION_MIRROR: 'https://{{ zuul_site_mirror_fqdn }}/ubuntu'
DIB_DEBIAN_COMPONENTS: 'main,universe'
- job:
name: opendev-promote-diskimage-ubuntu-resolute
parent: opendev-promote-diskimage-base
image-build-name: ubuntu-resolute