d436001b43
Commit 43b74ccc15
enabled use of Python 3
based packages but not switched to use Python 3.
Some of images still contain Python 2. There are two reasons:
- Ceph (ceph-common depends on Py2)
- python3-ldappool on Ubuntu 18.04
In Ceph situation Py3 packages were added. For second one we can not do
anything - Py2 dependency got dropped in Ubuntu 18.10 version.
Removed neutron-server-plugin-networking-infoblox due to being not
maintained. Once https://review.opendev.org/#/c/657578/ get merged
someone may revert that part.
Implements: blueprint debian-ubuntu-python3
Depends-on: Ie2a1077f7def0743f1403341985e2109aa490026
Change-Id: Ibfe0c2b8be98db56c61f74fb0247488ab3749ef4
62 lines
1.9 KiB
Django/Jinja
62 lines
1.9 KiB
Django/Jinja
FROM {{ namespace }}/{{ image_prefix }}base:{{ tag }}
|
|
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
|
|
|
|
{% block helm_repository_version %}
|
|
ENV helm_version=2.3.0 \
|
|
helm_port=8879 \
|
|
helm_address=0.0.0.0
|
|
{% endblock %}
|
|
|
|
{% block helm_repository_header %}{% endblock %}
|
|
|
|
{% import "macros.j2" as macros with context %}
|
|
|
|
{% if base_package_type == 'rpm' %}
|
|
{% set helm_repo_packages = [
|
|
'git',
|
|
'jq',
|
|
'python2-pip'
|
|
] %}
|
|
|
|
{% elif base_package_type == 'deb' %}
|
|
{% set helm_repo_packages = [
|
|
'git',
|
|
'jq',
|
|
'python3-pip'
|
|
] %}
|
|
|
|
{% endif %}
|
|
{{ macros.install_packages(helm_repo_packages | customizable("packages")) }}
|
|
|
|
{% block helm_repository_source_install_python_pip %}
|
|
{{ macros.get_pip() }}
|
|
{% endblock %}
|
|
|
|
{% set helm_repository_pip_packages = [
|
|
'pyyaml'
|
|
] %}
|
|
|
|
RUN {{ macros.install_pip(helm_repository_pip_packages | customizable("pip_packages"), constraints = false) }}
|
|
|
|
{% block helm_repository_install_kubernetes_helm %}
|
|
# TODO(mandre) check for file integrity instead of downloading from an HTTPS source
|
|
RUN curl -Lo /tmp/helm-v${helm_version}-linux-{{debian_arch}}.tar.gz https://storage.googleapis.com/kubernetes-helm/helm-v${helm_version}-linux-{{debian_arch}}.tar.gz \
|
|
&& sudo tar --strip-components 1 -C /usr/bin linux-{{debian_arch}}/helm -zxvf /tmp/helm-v${helm_version}-linux-{{debian_arch}}.tar.gz \
|
|
&& sudo chmod 755 /usr/bin/helm \
|
|
&& rm /tmp/helm-v${helm_version}-linux-{{debian_arch}}.tar.gz
|
|
{% endblock %}
|
|
|
|
RUN useradd --user-group --create-home --home-dir /home/helm helm \
|
|
&& sudo mkdir /helm-repo \
|
|
&& sudo chmod 755 /helm-repo \
|
|
&& sudo chown -R helm: /helm-repo/
|
|
|
|
USER helm
|
|
|
|
RUN helm init --client-only
|
|
|
|
CMD helm serve --address $helm_address:$helm_port --repo-path /helm-repo
|
|
|
|
{% block helm_repository_footer %}{% endblock %}
|
|
{% block footer %}{% endblock %}
|