Kolla provides production-ready containers and deployment tools for operating OpenStack clouds
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Dockerfile.j2 2.2KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. FROM {{ namespace }}/{{ image_prefix }}base:{{ tag }}
  2. LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
  3. {% block nova_libvirt_header %}{% endblock %}
  4. {% import "macros.j2" as macros with context %}
  5. {{ macros.configure_user(name='nova', groups='qemu') }}
  6. {% if base_distro in ['centos', 'oraclelinux', 'rhel'] %}
  7. {% set nova_libvirt_packages = [
  8. 'ceph-common',
  9. 'cyrus-sasl-scram',
  10. 'libguestfs',
  11. 'libvirt-client',
  12. 'libvirt-daemon',
  13. 'libvirt-daemon-config-nwfilter',
  14. 'libvirt-daemon-driver-lxc',
  15. 'libvirt-daemon-driver-nwfilter',
  16. 'openvswitch',
  17. ] %}
  18. {% if base_distro in ['centos', 'oraclelinux'] %}
  19. {% set nova_libvirt_packages = nova_libvirt_packages + [
  20. 'qemu-kvm-ev'
  21. ] %}
  22. {% else %}
  23. {% set nova_libvirt_packages = nova_libvirt_packages + [
  24. 'qemu-kvm'
  25. ] %}
  26. {% endif %}
  27. {% elif base_distro in ['debian', 'ubuntu'] %}
  28. {% set nova_libvirt_packages = [
  29. 'ceph-common',
  30. 'ebtables',
  31. 'libvirt-clients',
  32. 'libvirt-daemon-system',
  33. 'openvswitch-switch',
  34. 'pm-utils',
  35. 'qemu',
  36. 'qemu-block-extra'
  37. ] %}
  38. {% if base_arch == "aarch64" %}
  39. {% set nova_libvirt_packages = nova_libvirt_packages + [
  40. 'qemu-efi'
  41. ] %}
  42. {% endif %}
  43. {% if base_arch != "ppc64le" %}
  44. {% set nova_libvirt_packages = nova_libvirt_packages + [
  45. 'dmidecode',
  46. 'xen-utils'
  47. ] %}
  48. {% endif %}
  49. {% if base_distro in ['debian'] %}
  50. {% set nova_libvirt_packages = nova_libvirt_packages + [
  51. 'libpam-systemd/stretch-backports',
  52. 'usermode'
  53. ] %}
  54. {% endif %}
  55. {% endif %}
  56. {{ macros.install_packages(nova_libvirt_packages | customizable("packages")) }}
  57. {% if base_distro in ['debian', 'ubuntu'] %}
  58. RUN rm -f /etc/libvirt/qemu/networks/default.xml /etc/libvirt/qemu/networks/autostart/default.xml
  59. {% endif %}
  60. COPY extend_start.sh /usr/local/bin/kolla_extend_start
  61. RUN chmod 755 /usr/local/bin/kolla_extend_start
  62. {% block nova_libvirt_footer %}{% endblock %}
  63. {% block footer %}{% endblock %}