From: Marius Kittler <mkittler@suse.de>
To: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH] Add simple Containerfile
Date: Wed, 04 Oct 2023 14:28:59 +0200 [thread overview]
Message-ID: <2299373.ElGaqSPkdT@linux-9lzf> (raw)
In-Reply-To: <20230928104458.12115-1-rpalethorpe@suse.com>
> The container can be built with a command like:
>
> podman build -t tumbleweed/ltp \
> --build-arg PREFIX=registry.opensuse.org/opensuse/ \
> --build-arg DISTRO_NAME=tumbleweed \
> --build-arg DISTRO_RELEASE=20230925 .
>
> Or just
>
> podman build -t alpine/ltp .
>
> It contains Kirk in /opt/kirk. So
>
> cd /opt/kirk && ./kirk -f ltp -r syscalls
>
> will run some tests.
It would likely make sense to add a section with these information in the
README as well.
I'm also wondering about the workflow of making changes (e.g. to a single test)
and then re-compiling and re-running the specific test. Maybe that's also worth
considering/documenting.
>
> Note a much smaller container can be found at:
> https://registry.opensuse.org/cgi-bin/cooverview?srch_term=project%3D%5Ebenc
> hmark+container%3D.* This is created with SUSE's build system which does not
> use container files
>
> Signed-off-by: Richard Palethorpe <rpalethorpe@suse.com>
> Cc: Petr Vorel <pvorel@suse.cz>
> Cc: Marius Kittler <mkittler@suse.de>
> ---
>
> RFC comments:
> * Add git clean -fdX which should remove any build artifacts
> this is different from the suggestion of just doing a check. I just
> found it easier to remove the build files.
Where we document the usage of the container we should also document that
it'll do this kind of cleanup so there are no surprises.
> * Added seperate alpine and tumbleweed runtime scripts. Again it's
> different from the suggestion just because it's easier to add
> seperate scripts than adding a switch
> * Obviously a number of distros are missing runtime scripts. They can
> be added when someone is motivated to do so.
>
…
> +RUN mkdir /build
> +WORKDIR /build
> +COPY . /build
> +RUN ./ci/${DISTRO_NAME}.sh
> +RUN git clean -fdX
> +RUN ./build.sh -p $LTPROOT -i
> +
It might make sense to combine consecutive run commands (see
https://github.com/hadolint/hadolint/wiki/DL3059).
--
Mailing list info: https://lists.linux.it/listinfo/ltp
next prev parent reply other threads:[~2023-10-04 12:29 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-28 10:44 [LTP] [PATCH] Add simple Containerfile Richard Palethorpe via ltp
2023-09-28 18:11 ` Petr Vorel
2023-09-29 7:42 ` Richard Palethorpe
2023-09-29 8:15 ` Petr Vorel
2023-09-29 9:15 ` Richard Palethorpe
2023-09-29 9:37 ` Petr Vorel
2023-10-04 12:28 ` Marius Kittler [this message]
2023-10-05 8:07 ` Richard Palethorpe
2023-10-10 11:28 ` Andrea Cervesato via ltp
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2299373.ElGaqSPkdT@linux-9lzf \
--to=mkittler@suse.de \
--cc=ltp@lists.linux.it \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox