kolla-ansible/docker/ironic/ironic-pxe/Dockerfile.j2
Andrey Shestakov 56d24970fa Create ironic-pxe container with ironic-base
/tftpboot directory should be writeable by ironic-conductor.

TrivialFix

Change-Id: I870a786d41a6feb8e0786b6e86a5caf1f9ceb079
2015-12-28 19:55:34 +02:00

29 lines
730 B
Django/Jinja

FROM {{ namespace }}/{{ image_prefix }}ironic-base:{{ tag }}
MAINTAINER {{ maintainer }}
{% if base_distro in ['centos', 'fedora', 'oraclelinux', 'rhel'] %}
RUN yum -y install \
tftp-server \
syslinux-tftpboot \
&& yum clean all \
&& mkdir -p /tftpboot \
&& cp /var/lib/tftpboot/chain.c32 /tftpboot
{% elif base_distro in ['ubuntu', 'debian'] %}
RUN apt-get install -y --no-install-recommends \
tftpd-hpa \
syslinux-common \
syslinux \
&& apt-get clean \
&& mkdir -p /tftpboot \
&& chown -R ironic: /tftpboot \
&& cp /usr/lib/syslinux/pxelinux.0 /usr/lib/syslinux/chain.c32 /tftpboot
{% endif %}
COPY tftp-map-file /tftpboot/map-file
{{ include_footer }}