[Tarantool-patches] [PATCH 2/3] github-ci: add init option for containers

Alexander Turenko alexander.turenko at tarantool.org
Tue Dec 29 22:25:36 MSK 2020


Pushed out of order to fix our CI to master, 2.6, 2.5 and 1.10.

Made several changes as listed below.

WBR, Alexander Turenko.

On Tue, Dec 29, 2020 at 07:25:34PM +0300, Artem Starshov wrote:
> From: Alexander Turenko <alexander.turenko at tarantool.org>
> 
> Now we have a PID 1 zombie reaping problem, when zombie
> processes launched in Docker aren't collected by init,
> how it would be done if we launch it on Unix.

It is a bit imprecise: 'Docker' and 'Unix' are not opposites. Changed to
'launch it on a real host'.

> 
> It is fixed by adding --init option, when image launched.

This is a bit imprecise too: a container is created/started, not an image.
Changed to 'when a container is created or started'. I replaced the term
'launched', because actual commands are 'docker create' or 'docker
start' (you can see it in CI logs).

> 
> Co-authored-by: Artem Starshov <artemreyt at tarantool.org>

Added 'Follows up #4983'.

> ---
>  .github/workflows/coverity.yml             | 6 +++++-
>  .github/workflows/debian_11.yml            | 1 +
>  .github/workflows/debug_coverage.yml       | 6 +++++-
>  .github/workflows/luacheck.yml             | 6 +++++-
>  .github/workflows/release.yml              | 6 +++++-
>  .github/workflows/release_asan_clang11.yml | 6 +++++-
>  .github/workflows/release_clang.yml        | 6 +++++-
>  .github/workflows/release_lto.yml          | 6 +++++-
>  .github/workflows/release_lto_clang11.yml  | 6 +++++-
>  9 files changed, 41 insertions(+), 8 deletions(-)
> 
> diff --git a/.github/workflows/coverity.yml b/.github/workflows/coverity.yml
> index c8f370033..a265b3dab 100644
> --- a/.github/workflows/coverity.yml
> +++ b/.github/workflows/coverity.yml
> @@ -22,7 +22,11 @@ jobs:
>      # Image built by .gitlab.mk instructions and targets from .travis.mk.
>      # Also additional installation of coverity tool installation check
>      # exists in target deps_coverity_debian at .travis.mk file.
> -    container: docker.io/tarantool/testing:debian-buster
> +    container:
> +      image: docker.io/tarantool/testing:debian-buster
> +      # We lean on reaping processes by the init process (PID 1)
> +      # in tests.
> +      options: '--init'

That wording was in my fast-try-do-not-merge commit.

Reworded to make it sound a bit more elegant for me (and added the test
name):

 | # Our testing expects that the init process (PID 1) will
 | # reap orphan processes. At least the following test leans
 | # on it: app-tap/gh-4983-tnt-e-assert-false-hangs.test.lua.

>  
>      steps:
>        - uses: actions/checkout at v1
> diff --git a/.github/workflows/debian_11.yml b/.github/workflows/debian_11.yml
> index 06008c231..84db2644d 100644
> --- a/.github/workflows/debian_11.yml
> +++ b/.github/workflows/debian_11.yml
> @@ -24,6 +24,7 @@ jobs:
>            submodules: recursive
>        - name: packaging
>          env:
> +          PACKPACK_EXTRA_DOCKER_RUN_PARAMS: '--init'
>            AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
>            AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
>            AWS_S3_ENDPOINT_URL: ${{ secrets.AWS_S3_ENDPOINT_URL }}

Added the comment here too.


More information about the Tarantool-patches mailing list