Skip to content

Commit 2df836b

Browse files
committed
Improve offline build scenario.
* Use distribution based dumb-init package. Change-Id: I75927b6016bdb7577fbff354632bdab6407f359c Related-Bug: #19311980 (cherry picked from commit 5940d17)
1 parent f28f4a9 commit 2df836b

File tree

2 files changed

+9
-11
lines changed

2 files changed

+9
-11
lines changed

docker/base/Dockerfile.j2

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -258,6 +258,7 @@ RUN {{ macros.install_packages(base_centos_yum_repo_packages | customizable("cen
258258
{% set base_centos_packages = [
259259
'ca-certificates',
260260
'curl',
261+
'dumb-init',
261262
'findutils',
262263
'iproute',
263264
'iscsi-initiator-utils',
@@ -328,6 +329,7 @@ COPY apt_preferences /etc/apt/preferences.d/kolla-custom
328329
{% set base_apt_packages = [
329330
'apt-utils',
330331
'curl',
332+
'dumb-init',
331333
'gawk',
332334
'iproute2',
333335
'kmod',
@@ -340,8 +342,8 @@ COPY apt_preferences /etc/apt/preferences.d/kolla-custom
340342
'python3-setuptools',
341343
'socat',
342344
'sudo',
343-
'tgt']
344-
%}
345+
'tgt'
346+
] %}
345347

346348
{% if base_distro == 'ubuntu' %}
347349
{# 391A9AA2147192839E9DB0315EDB1B62EC4926EA -- Canonical Cloud Archive Signing Key <[email protected]> #}
@@ -427,16 +429,7 @@ COPY httpd_setup.sh /usr/local/bin/kolla_httpd_setup
427429
COPY sudoers /etc/sudoers
428430

429431
{% if use_dumb_init %}
430-
431-
{% block dumb_init_installation %}
432-
433-
RUN curl -sSL https://github.com/Yelp/dumb-init/releases/download/v1.2.2/dumb-init_1.2.2_{{debian_arch}} -o /usr/local/bin/dumb-init \
434-
&& chmod +x /usr/local/bin/dumb-init
435-
436-
{% endblock %}
437-
438432
ENTRYPOINT ["dumb-init", "--single-child", "--"]
439-
440433
{% endif %}
441434

442435
{% if docker_healthchecks %}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
features:
3+
- |
4+
Improve the way offline scenario are supported:
5+
* Switching dumb-init installation to distribution provided packages.

0 commit comments

Comments
 (0)