Skip to content

Nova

The nova image is built from ContainerFiles/nova. Security patches are applied by scripts/nova-cve-patching.sh.

This container packages the Nova service for use in the stack. The build installs the required packages, applies security updates and configuration, and prepares the service for integration.

graph LR
    A[Base image] --> B[Install packages]
    B --> C[Apply CVE patches]
    C --> D[Configure Nova]
    D --> E[Container ready]
    Libguestfs --> A
ContainerFile used for the build
# syntax = docker/dockerfile:1
# This Dockerfile uses multi-stage build to customize DEV and PROD images:
# https://docs.docker.com/develop/develop-images/multistage-build/

ARG OS_VERSION=master
ARG OS_CONSTRAINTS=master
ARG NOVA_REPOSITORY=https://opendev.org/openstack/nova.git
ARG NOVA_FLAVOR_QOS_REPOSITORY=https://github.com/rackerlabs/rxt-nova-flavor-qos.git
# The flavor-qos plugin is a Rackspace fork maintained on a rolling branch, not
# an OpenStack stable branch: use stable/2026.1 for Gazpacho and main elsewhere
# (2025.1/Epoxy has no fork branch; main is the supported line, matching neutron).
ARG NOVA_FLAVOR_QOS_VERSION=main

FROM ubuntu:noble AS base

ARG CACHEBUST=0
ARG OS_VERSION
ARG OS_CONSTRAINTS
ARG NOVA_REPOSITORY
ARG NOVA_FLAVOR_QOS_REPOSITORY
ARG NOVA_FLAVOR_QOS_VERSION

RUN apt-get update \
  && apt-get install -y --no-install-recommends \
               bash \
               build-essential \
               curl \
               git \
               libcairo2-dev \
               libffi-dev \
               libgirepository1.0-dev \
               libjs-sphinxdoc \
               libjs-underscore \
               libldap2-dev \
               libpq-dev \
               libsasl2-dev \
               libssl-dev \
               libsystemd-dev \
               libxml2-dev \
               libvirt-dev \
               libxslt1-dev \
               patch \
               python3 \
               python3-dev \
               python3-venv \
               python3-pip \
  && rm -rf /var/lib/apt/lists/*

RUN python3 -m venv --system-site-packages /var/lib/openstack \
  && /var/lib/openstack/bin/pip install --upgrade pip \
  && /var/lib/openstack/bin/pip install --constraint https://opendev.org/openstack/requirements/raw/branch/${OS_CONSTRAINTS}/upper-constraints.txt \
                                               git+${NOVA_REPOSITORY}@${OS_VERSION}#egg=nova \
                                               git+${NOVA_FLAVOR_QOS_REPOSITORY}@${NOVA_FLAVOR_QOS_VERSION}#egg=rxt-nova-flavor-qos \
                                               git+https://opendev.org/openstack/blazar-nova.git@${OS_VERSION}#egg=blazar-nova \
                                               PyMySQL \
                                               libvirt-python \
                                               novnc \
                                               python-memcached \
                                               websockify \
                                               uwsgi

RUN test -x /var/lib/openstack/bin/nova-compute \
  && test -x /var/lib/openstack/bin/nova-flavor-qos-compute \
  && /var/lib/openstack/bin/python -c "from rxt_nova_flavor_qos.compute import FlavorQosComputeManager" \
  && mv /var/lib/openstack/bin/nova-compute /var/lib/openstack/bin/nova-compute.stock \
  && ln -s nova-flavor-qos-compute /var/lib/openstack/bin/nova-compute \
  && test "$(readlink /var/lib/openstack/bin/nova-compute)" = "nova-flavor-qos-compute"

COPY dist/novnc.tar.gz /tmp/novnc.tar.gz
RUN mkdir -p /usr/share/novnc \
  && tar -xzf /tmp/novnc.tar.gz -C /usr/share/novnc --strip-components=1 \
  && rm /tmp/novnc.tar.gz
RUN cp -v /usr/share/novnc/vnc_lite.html /usr/share/novnc/vnc_auto.html

COPY scripts/nova-cve-patching.sh /opt/
RUN bash /opt/nova-cve-patching.sh

COPY patches/nova/resize-local-disk-preflight-master.patch /opt/
COPY patches/nova/resize-local-disk-preflight-stable-2026.1.patch /opt/
COPY scripts/nova-resize-preflight-patch.sh /opt/
RUN bash /opt/nova-resize-preflight-patch.sh

RUN find / -name '*.pyc' -delete \
  && find / -name '*.pyo' -delete \
  && find / -name '__pycache__' -delete \
  && find / -name '*.whl' -delete \
  && rm -f /var/lib/openstack/lib/python*/site-packages/slapdtest/certs/client.key \
  && rm -f /var/lib/openstack/lib/python*/site-packages/slapdtest/certs/server.key \
  && sed -i '/^Usage/,/^Documentation\n^-.*$/d' /var/lib/openstack/lib/python*/site-packages/PyJWT-*.dist-info/METADATA || true


FROM ubuntu:noble
LABEL maintainer="Rackspace"
LABEL vendor="Rackspace OpenStack Team"
LABEL org.opencontainers.image.name="nova"
LABEL org.opencontainers.image.description="OpenStack Service (nova) built for the enterprise."
COPY --from=base /var/lib/openstack /var/lib/openstack
COPY --from=base /usr/share/novnc /usr/share/novnc

RUN apt-get update \
  && apt-get install -y --no-install-recommends ceph-common \
                                                 cryptsetup \
                                                 dosfstools \
                                                 genisoimage \
                                                 gir1.2-libosinfo-1.0 \
                                                 iptables \
                                                 kpartx \
                                                 ksmtuned \
                                                 libgirepository-1.0-1 \
                                                 libguestfs0 \
                                                 libosinfo-bin \
                                                 libxml2 \
                                                 multipath-tools \
                                                 netcat-openbsd \
                                                 nfs-common \
                                                 nvme-cli \
                                                 lsscsi \
                                                 open-iscsi \
                                                 ovmf \
                                                 python3-ceph-argparse \
                                                 python3-ceph-common \
                                                 python3-cephfs \
                                                 python3-rados \
                                                 python3-rbd \
                                                 sysfsutils \
                                                 sudo \
                                                 ssh \
                                                 uwsgi \
                                                 uwsgi-plugin-python3 \
  && apt-get purge -y --auto-remove \
  && apt-get clean -y \
  && rm -rf /var/lib/apt/lists/* \
  && find / -name '*.pyc' -delete \
  && find / -name '*.pyo' -delete \
  && find / -name '__pycache__' -delete \
  && groupadd --system --gid 42424 nova \
  && useradd --system --gid 42424 --uid 42424 --shell /bin/bash --create-home --home /var/lib/nova nova \
  && mkdir -p /var/lib/openstack/etc/nova \
  && ln -s /var/lib/openstack/etc/nova /etc/nova \
  && chown nova:nova -h /etc/nova \
  && chown -R nova:nova /var/lib/openstack/etc/nova

# Set the environment variables for the nova venv
ENV PATH="/var/lib/openstack/bin:$PATH"
# Set the working directory
WORKDIR /var/lib/openstack
# Set the user and group to match the original build
USER 42424:42424
# Set the entrypoint to the nova-manage command
ENTRYPOINT ["/var/lib/openstack/bin/nova-manage"]

Build Arguments

Argument Default
BUILT_TAG v1.56.1-latest
OS_VERSION master
OS_CONSTRAINTS master
NOVA_REPOSITORY https://opendev.org/openstack/nova.git
NOVA_FLAVOR_QOS_REPOSITORY https://github.com/rackerlabs/rxt-nova-flavor-qos.git
NOVNC_VERSION master

rxt-nova-flavor-qos uses OS_VERSION, keeping its branch aligned with the Nova branch selected by the build workflow (for example, stable/2026.1).

Build Command
docker build \
--build-arg BUILT_TAG=v1.56.1-latest \
--build-arg OS_VERSION=stable/2026.1 \
--build-arg OS_CONSTRAINTS=stable/2026.1 \
--build-arg NOVA_REPOSITORY=https://opendev.org/openstack/nova.git \
--build-arg NOVA_FLAVOR_QOS_REPOSITORY=https://github.com/rackerlabs/rxt-nova-flavor-qos.git \
--build-arg NOVNC_VERSION=master \
-f ContainerFiles/nova \
-t nova:2026.1-flavor-qos \
.

The Nova and rxt-nova-flavor-qos repositories are installed into the same /var/lib/openstack virtual environment.

The image preserves the stock executable as nova-compute.stock and links nova-compute to the adapter entry point:

/var/lib/openstack/bin/nova-compute -> nova-flavor-qos-compute

This lets the existing Helm compute workload continue invoking nova-compute without a chart change. API, conductor, scheduler, and utility workloads use their normal Nova executables and are unaffected. A compute workload can use /var/lib/openstack/bin/nova-compute.stock as an explicit operational rollback without rebuilding the image.

Dependencies

Container Image

The container image is available on Github Container Registry.