openstack-client
The openstack-client image is built from ContainerFiles/openstack-client. Security patches are applied by scripts/openstack-client-cve-patching.sh.
This container packages the openstack-client service for use in the stack. The build installs the required packages, applies security updates and configuration, and prepares the service for integration.
The build installs all client packages against the upper constraints of the
OpenStack release it targets. Supported OS_VERSION values are unmaintained/2025.1
for Epoxy and stable/2026.1 for Gazpacho.
OS_VERSION has no default. The release is supplied by the build workflow,
which builds every supported release on a matrix. A build that does not pass
OS_VERSION fails.
Published tags carry the release and the python-openstackclient version
resolved during the build:
| Tag | Meaning |
|---|---|
2025.1-latest |
newest build for the release |
2025.1-7.5.1 |
the specific client release version |
2025.1-7.5.1-1758830017 |
immutable per-build record |
2025.1-1758830017 |
same build, retained for compatibility |
graph LR
A[Base image] --> B[Install packages]
B --> C[Apply CVE patches]
C --> D[Configure openstack-client]
D --> E[Container ready]
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 VENV_TAG=3.12-latest
FROM ghcr.io/rackerlabs/genestack-images/openstack-venv:${VENV_TAG} AS dependency_build
ARG CACHEBUST=0
# No default: the release is supplied by the build workflow.
ARG OS_VERSION
RUN export DEBIAN_FRONTEND=noninteractive \
&& apt-get update && apt-get upgrade -y \
&& apt-get install --no-install-recommends -y \
bash \
build-essential \
curl \
docutils-common \
gettext \
git \
libffi-dev \
pkg-config \
ssl-cert
# package list pulled from here: https://opendev.org/openstack/heat/src/branch/master/requirements.txt
RUN set -eux; \
if [ -z "${OS_VERSION}" ]; then \
echo "OS_VERSION build-arg is required and has no default." >&2; \
echo "Pass the release being built, e.g. --build-arg OS_VERSION=unmaintained/2025.1" >&2; \
exit 1; \
fi; \
case "${OS_VERSION}" in \
unmaintained/2025.1|2025.1|epoxy) OS_CONSTRAINTS=unmaintained/2025.1 ;; \
stable/2026.1|2026.1|gazpacho|gazapacho) OS_CONSTRAINTS=stable/2026.1 ;; \
*) echo "Unsupported OS_VERSION=${OS_VERSION}. Supported releases: unmaintained/2025.1, stable/2026.1" >&2; exit 1 ;; \
esac; \
/var/lib/openstack/bin/pip install --constraint https://opendev.org/openstack/requirements/raw/branch/${OS_CONSTRAINTS}/upper-constraints.txt \
pbr \
alembic \
croniter \
cryptography \
gnocchiclient \
keystoneauth1 \
keystonemiddleware \
lxml \
mysqlclient \
netaddr \
neutron-lib \
openstacksdk \
oslo.cache\
oslo.config \
oslo.concurrency \
oslo.context \
oslo.db \
oslo.i18n \
oslo.log \
oslo.messaging \
oslo.middleware \
oslo.policy \
oslo.reports \
oslo.serialization \
oslo.service[threading] \
oslo.upgradecheck \
oslo.utils \
osprofiler \
oslo.versionedobjects \
PasteDeploy \
aodhclient \
pyMySql \
python-barbicanclient \
python-blazarclient \
python-cinderclient \
python-cloudkittyclient \
python-designateclient \
python-glanceclient \
python-heatclient \
python-ironicclient \
python-keystoneclient \
python-magnumclient \
python-manilaclient \
python-masakariclient \
python-mistralclient \
python-neutronclient \
python-novaclient \
python-octaviaclient \
python-openstackclient \
python-swiftclient \
python-troveclient \
python-vitrageclient \
python-zaqarclient \
python-zunclient \
osc-placement \
PyYAML \
requests \
tenacity \
tzdata \
Routes \
SQLAlchemy \
stevedore \
WebOb \
yaql
COPY scripts/openstack-client-cve-patching.sh /opt/
RUN bash /opt/openstack-client-cve-patching.sh
COPY scripts/blazar-client-host-unset-patch.sh /opt/
RUN bash /opt/blazar-client-host-unset-patch.sh
# Record the resolved client version so the workflow can tag with it.
RUN /var/lib/openstack/bin/python -c \
"from importlib.metadata import version; print(version('python-openstackclient'))" \
> /var/lib/openstack/openstack-client-release \
&& test -s /var/lib/openstack/openstack-client-release
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
FROM python:3.12-slim-bookworm
# No default: the release is supplied by the build workflow.
ARG OS_VERSION
LABEL maintainer="Rackspace"
LABEL vendor="Rackspace OpenStack Team"
LABEL org.opencontainers.image.name="openstack-client"
LABEL org.opencontainers.image.description="OpenStack Client (openstack-client) built for the enterprise."
LABEL org.opencontainers.image.openstack.version="${OS_VERSION}"
COPY --from=dependency_build /var/lib/openstack /var/lib/openstack
RUN export DEBIAN_FRONTEND=noninteractive \
&& if [ -z "${OS_VERSION}" ]; then \
echo "OS_VERSION build-arg is required and has no default." >&2; \
exit 1; \
fi \
&& apt-get update && apt-get upgrade -y \
&& apt-get install --no-install-recommends -y curl \
iputils-ping \
libxml2 \
libxslt1.1 \
libopenmpi3 \
netcat-openbsd \
mariadb-client \
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
&& apt-get clean -y \
&& rm -rf /var/lib/apt/lists/* \
&& mkdir -p /etc/genestack \
&& printf '%s\n' "${OS_VERSION}" > /etc/genestack/openstack-version \
&& mv /var/lib/openstack/openstack-client-release /etc/genestack/openstack-client-release \
&& find / -name '*.pyc' -delete \
&& find / -name '*.pyo' -delete \
&& find / -name '__pycache__' -delete \
&& groupadd --system --gid 42424 openstack-client \
&& useradd --system --gid 42424 --uid 42424 --shell /sbin/nologin --create-home --home /var/lib/openstack-client openstack-client \
&& mkdir -p /var/lib/openstack/etc/openstack-client \
&& ln -s /var/lib/openstack/etc/openstack-client /etc/openstack-client \
&& chown openstack-client:openstack-client -h /etc/openstack-client \
&& chown -R openstack-client:openstack-client /var/lib/openstack/etc/openstack-client
# Set the environment variables for the openstack-client 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
Build Arguments
| Argument | Default |
|---|---|
| VENV_TAG | 3.12-latest |
| CACHEBUST | 0 |
| OS_VERSION | none, required |
Build Command
Dependencies
- Builds From OpenStack Virtual Environment
Container Image
The container image is available on Github Container Registry.