b18b6a6d1d
Change-Id: I1a7533c738edeff4e696e95b9b267c23a78003e9 Closes-Bug: #1796194
115 lines
3.5 KiB
Django/Jinja
115 lines
3.5 KiB
Django/Jinja
FROM {{ namespace }}/{{ image_prefix }}ironic-base:{{ tag }}
|
|
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
|
|
|
|
{% block ironic_conductor_header %}{% endblock %}
|
|
|
|
{% import "macros.j2" as macros with context %}
|
|
|
|
{% if install_type == 'binary' %}
|
|
{% if base_distro in ['centos', 'oraclelinux', 'rhel'] %}
|
|
# TODO(Jeffrey4l): no python-oneviewclient
|
|
{% set ironic_conductor_packages = [
|
|
'ansible',
|
|
'dosfstools',
|
|
'e2fsprogs',
|
|
'gdisk',
|
|
'ipmitool',
|
|
'openstack-ironic-conductor',
|
|
'openstack-ironic-staging-drivers',
|
|
'parted',
|
|
'psmisc',
|
|
'pysnmp',
|
|
'python2-ImcSdk',
|
|
'python-dracclient',
|
|
'python-ironic-inspector-client',
|
|
'python-proliantutils',
|
|
'python-scciclient',
|
|
'python-sushy',
|
|
'python-UcsSdk',
|
|
'shellinabox',
|
|
'systemd-python',
|
|
'util-linux',
|
|
'xfsprogs',
|
|
] %}
|
|
{% if base_distro in ['centos', 'oraclelinux'] %}
|
|
{% set ironic_conductor_packages = ironic_conductor_packages + [
|
|
'qemu-img-ev'
|
|
] %}
|
|
{% else %}
|
|
{% set ironic_conductor_packages = ironic_conductor_packages + [
|
|
'qemu-img'
|
|
] %}
|
|
{% endif %}
|
|
{% elif base_distro in ['debian', 'ubuntu'] %}
|
|
# TODO(jeffrey4l): no python-dracclient, python-oneviewclient, UcsSdk,
|
|
# ImcSdk package, python-sushy, ironic-staging-drivers
|
|
{% set ironic_conductor_packages = [
|
|
'ansible',
|
|
'bsdmainutils',
|
|
'dosfstools',
|
|
'e2fsprogs',
|
|
'gdisk',
|
|
'ipmitool',
|
|
'ironic-conductor',
|
|
'parted',
|
|
'psmisc',
|
|
'python-ironic-inspector-client',
|
|
'python-proliantutils',
|
|
'python-pysnmp4',
|
|
'python-scciclient',
|
|
'python-systemd',
|
|
'qemu-utils',
|
|
'shellinabox',
|
|
'xfsprogs',
|
|
] %}
|
|
{% endif %}
|
|
{% elif install_type == 'source' %}
|
|
{% if base_distro in ['centos', 'oraclelinux', 'rhel'] %}
|
|
{% set ironic_conductor_packages = [
|
|
'dosfstools',
|
|
'e2fsprogs',
|
|
'fuse',
|
|
'gdisk',
|
|
'ipmitool',
|
|
'parted',
|
|
'psmisc',
|
|
'qemu-img-ev',
|
|
'shellinabox',
|
|
'util-linux',
|
|
'xfsprogs',
|
|
] %}
|
|
{% elif base_distro in ['debian', 'ubuntu'] %}
|
|
{% set ironic_conductor_packages = [
|
|
'bsdmainutils',
|
|
'dosfstools',
|
|
'e2fsprogs',
|
|
'gdisk',
|
|
'ipmitool',
|
|
'parted',
|
|
'psmisc',
|
|
'qemu-utils',
|
|
'shellinabox',
|
|
'xfsprogs',
|
|
] %}
|
|
{% endif %}
|
|
|
|
{% set ironic_conductor_pip_packages = [
|
|
'-r /ironic/driver-requirements.txt',
|
|
'ironic-staging-drivers',
|
|
] %}
|
|
|
|
RUN {{ macros.install_pip(ironic_conductor_pip_packages | customizable("pip_packages")) }}
|
|
{% endif %}
|
|
|
|
{{ macros.install_packages(ironic_conductor_packages | customizable("packages")) }}
|
|
|
|
COPY extend_start.sh /usr/local/bin/kolla_ironic_extend_start
|
|
COPY iscsi_tcp_sudoers /etc/sudoers.d/kolla_iscsi_tcp_sudoers
|
|
RUN chmod 755 /usr/local/bin/kolla_ironic_extend_start \
|
|
&& chmod 440 /etc/sudoers.d/kolla_iscsi_tcp_sudoers
|
|
|
|
{% block ironic_conductor_footer %}{% endblock %}
|
|
{% block footer %}{% endblock %}
|
|
|
|
USER ironic
|