summaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
* enable staticcheck linterPaul Holzinger2022-04-22
| | | | | | | Fix many problems reported by the staticcheck linter, including many real bugs! Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* Merge pull request #13958 from cevich/fix_system_criu_relinkOpenShift Merge Robot2022-04-22
|\ | | | | Workaround criu re-linking output in system test
| * Workaround criu re-linking output in system testChris Evich2022-04-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When run on an F36 host using netavark/aardvark-dns, for whatever underlying reason most checkpoint/restore tests are emitting an error similar to: `criu: Symbol `__rseq_offset' has different size in shared object, consider re-linking` This extraneous output is causing the basic checkpoint system test to fail. Since, all other testing of checkpoint/restore feature is passing (also with the extraneous message) loosen the system test sensitivity to match. Signed-off-by: Chris Evich <cevich@redhat.com>
* | Merge pull request #13963 from flouthoc/revert-entrypoint-compatOpenShift Merge Robot2022-04-21
|\ \ | |/ |/| Revert "container,inspect: convert Entrypoint to array instead of a string
| * Revert "container,inspect: convert Entrypoint to array instead of a string"Aditya R2022-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | It seems this breaks older version of `podman-remote` users hence it looks like this patch would be a better candidate for podman `5.0` Problem * Client with `4.0` cannot interact with a server of `4.1` Plan this patch for podman `5.0` This reverts commit 0cebd158b6d8da1828b1255982e27fe9224310d0. Signed-off-by: Aditya R <arajan@redhat.com>
* | Merge pull request #13957 from cevich/fix_remote_netavarkOpenShift Merge Robot2022-04-21
|\ \ | | | | | | Fix using --network-backend on podman-remote
| * | Fix using --network-backend on podman-remoteChris Evich2022-04-21
| |/ | | | | | | | | | | | | | | | | | | When this option was added to the e2e tests, there was no CI Automation support for running remote tests w/ netavark. When added, many e2e test errors/failures are generated due to this option not being valid for the remote client. Fix this in the tests by conditionally adding the option if the test is running the remote client. Signed-off-by: Chris Evich <cevich@redhat.com>
* / Fix upgrade tests assuming storage.conf existsChris Evich2022-04-21
|/ | | | | | | | | | On F36 / podman 4, at the time of this commit there is no `/etc/containers/storage.conf` installed by default. Since the test volume-mounts this file into the container, it was failing. Fix this by using a conditional volume-mount based on the file existing (or not). Signed-off-by: Chris Evich <cevich@redhat.com>
* Merge pull request #13505 from rst0git/checkpoint-image-1OpenShift Merge Robot2022-04-21
|\ | | | | Add support for checkpoint image
| * Add checkpoint image testsRadostin Stoyanov2022-04-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The patch introduces the following test cases: 1. An attempt to checkpoint a container that does not exist should fail. 2. Checkpoint of a running container with --create-image should create a checkpoint image. 3. A single checkpoint image can be used to restore multiple containers, each with a different name. 4. Restoring multiple containers from checkpoint images with a single restore command. Signed-off-by: Radostin Stoyanov <radostin@redhat.com>
* | Fix e2e tests referencing generic env. var.Chris Evich2022-04-20
|/ | | | | | | | | | | Use of `$DEBUG` is highly likely to clash. Fortunately this one is in a very specific/special context, so a rename fix should be perfectly adequate. See also https://github.com/containers/automation/pull/96 and https://github.com/containers/podman/issues/13932 Signed-off-by: Chris Evich <cevich@redhat.com>
* Merge pull request #13835 from vrothberg/run-1436OpenShift Merge Robot2022-04-20
|\ | | | | benchmarking Podman: proof of concept
| * benchmarking Podman: proof of conceptValentin Rothberg2022-04-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a proof of concept for benchmarking Podman. The benchmarks are implemented by means of the end-to-end test suite but hidden behind a `benchmarks` build tag. Running `make localbenchmarks` will run `test/e2e` with the specific build tag and set ginkgo's "focus" to the specific "Podman Benchmark Suite" to only run this spec and skip all others. ginkgo will print a report before terminating listing the CPU and memory stats for each benchmark. New benchmarks can easily be added via the `newBenchmark` function that also supports adding an `init()` function to each benchmark which allows for performing certain setups for the specific benchmark. For instance, benchmarking `podman start` requires creating a container beforehand. Podman may be called more than once in the main function of a benchmark but note that the displayed memory consumption is then a sum of all Podman invocations. The memory consumption is collected via `/usr/bin/time`. A benchmark's report is split into CPU and memory as displayed below: ``` [CPU] podman images: Fastest Time: 0.146s Slowest Time: 0.187s Average Time: 0.180s ± 0.015s [MEM] podman images: Smallest: 41892.0KB Largest: 42792.0KB Average: 42380.7KB ± 286.4KB ``` Note that the benchmarks are not wired into the CI yet. They are meant as a proof of concept. More benchmarks and the plumbing into CI will happen in a later change. Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | healthcheck: set default healthcheck Interval if not specified in imageAditya R2022-04-20
|/ | | | | | | Set appropriate defaults for `--interval` when processing a Containerfile with build format as docker. Signed-off-by: Aditya R <arajan@redhat.com>
* Translate Memory Limit to Swap in APIcdoern2022-04-18
| | | | | | | | | in specgen, CLI path uses the given memory limit to define the swap value (if not already specified) add a route to this piece of code from within the api handlers resolves #13145 Signed-off-by: cdoern <cdoern@redhat.com>
* Merge pull request #13583 from rhatdan/ipcOpenShift Merge Robot2022-04-16
|\ | | | | Add support for ipc namespace modes "none, private, sharable"
| * Add support for ipc namespace modes "none, private, sharable"Daniel J Walsh2022-04-12
| | | | | | | | | | | | Fixes: #13265 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | Merge pull request #13641 from nicrowe00/logfileOpenShift Merge Robot2022-04-15
|\ \ | | | | | | Add log rotation based on log size
| * | Add log rotation based on log sizeNiall Crowe2022-04-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add new functions to logfile.go for rotating and truncating the events log file once the log file and its contents exceed the maximum size limit while keeping 50% of the log file's content Also add tests to verify log rotation and truncation Signed-off-by: Niall Crowe <nicrowe@redhat.com> Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | | Merge pull request #13868 from cdoern/cloneSwapOpenShift Merge Robot2022-04-15
|\ \ \ | | | | | | | | Fix Memory Swappiness passing in Container Clone
| * | | Fix Memory Swappiness passing in Container Clonecdoern2022-04-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `DefineCreateFlags` was excluding clone from using the memory-swappiness flag leading the value to be zero when our deafult is -1. Rearrange the if/else to give clone these memory related options resolves #13856 Signed-off-by: cdoern <cdoern@redhat.com>
* | | | Merge pull request #13616 from giuseppe/passwd-entryOpenShift Merge Robot2022-04-14
|\ \ \ \ | | | | | | | | | | run, create: add --passwd-entry
| * | | | run, create: add --passwd-entryGiuseppe Scrivano2022-04-14
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It allows to customize the entry that is written to the `/etc/passwd` file when --passwd is used. Closes: https://github.com/containers/podman/issues/13185 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | | | add a regression test for CVE-2022-1227Valentin Rothberg2022-04-14
| | | | | | | | | | | | | | | | | | | | | | | | Will also be included in the upcoming backports. Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | | | Merge pull request #13866 from edsantiago/batsOpenShift Merge Robot2022-04-14
|\ \ \ \ | | | | | | | | | | System tests: Usage checks: better error messages
| * | | | System tests: Usage checks: better error messagesEd Santiago2022-04-13
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | Current error messages are really awful, and cause great suffering every time someone adds a new subcommand. Let's see if these are better. Signed-off-by: Ed Santiago <santiago@redhat.com>
* | | | Merge pull request #13857 from rhatdan/logsOpenShift Merge Robot2022-04-14
|\ \ \ \ | | | | | | | | | | Fix --tail log on restart problem
| * | | | Fix --tail log on restart problemDaniel J Walsh2022-04-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --tail=1 is not working f you restart a container with journald logging. We see the exit status and then call into the logging a second time causing all of the logs to print. Removing the tail log on exited seems to fix the problem. Fixes: https://github.com/containers/podman/issues/13098 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | | | | Merge pull request #13872 from vrothberg/revert-sizeOpenShift Merge Robot2022-04-14
|\ \ \ \ \ | |_|/ / / |/| | | | Revert "images --size"
| * | | | Revert "images --size"Valentin Rothberg2022-04-14
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit e133a06d2f4a3e94bfbd60b647046f2f515c9c24. @nalind found a proper fix in c/storage [1] to address the performance issue. So we really don't need the flag anymore. Note the flag has never made it into any release. [1] https://github.com/containers/storage/commit/d76b3606fc9ca975bf436379f91105f0fac1555f Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* / / / compat api: use network mode bridge as defaultPaul Holzinger2022-04-13
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For better docker compatibility we should use the bridge network mode as default for rootless. This was already done previously but commit 535818414c2a introduced this regression in v4.0. Since the apiv2 test are only run rootful we cannot catch this problem in CI. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* | | Merge pull request #13846 from edsantiago/batsOpenShift Merge Robot2022-04-12
|\ \ \ | | | | | | | | System tests: fix oops in start --filter tests
| * | | System tests: fix oops in start --filter testsEd Santiago2022-04-12
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | Bad code got committed by accident: test description on run_podman line, not test line. Did not seem to affect tests, but fix it anyway. Signed-off-by: Ed Santiago <santiago@redhat.com>
* | | Merge pull request #13787 from Luap99/nohost-apiOpenShift Merge Robot2022-04-12
|\ \ \ | |_|/ |/| | API: use no_hosts from containers.conf
| * | API: use no_hosts from containers.confPaul Holzinger2022-04-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | The API endpoints should properly honour the `no_hosts=true` setting in containers.conf. Fixes #13719 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* | | Merge pull request #13788 from flouthoc/support-volume-optsOpenShift Merge Robot2022-04-12
|\ \ \ | |_|/ |/| | run, mount: allow setting driver specific option using `volume-opt=`
| * | run, mount: allow setting driver specific option using volume-optAditya R2022-04-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | `--mount` should allow setting driver specific options using `volume-opt` when `type=volume` is set. This ensures parity with docker's `volume-opt`. Signed-off-by: Aditya R <arajan@redhat.com>
* | | Merge pull request #13822 from edsantiago/buildah_3544_fixedOpenShift Merge Robot2022-04-11
|\ \ \ | | | | | | | | System tests: reenable ps --external test
| * | | System tests: reenable ps --external testEd Santiago2022-04-11
| | |/ | |/| | | | | | | | | | | | | | | | Buildah issue 3544 has been fixed and vendored into podman. We can reenable a long-skipped test. Signed-off-by: Ed Santiago <santiago@redhat.com>
* / | network create: add support for ipam-driver nonePaul Holzinger2022-04-11
|/ / | | | | | | | | | | | | | | | | Add a new flag to set the ipam-driver. Also adds a new ipam driver none mode which only creates interfaces but does not assign addresses. Fixes #13521 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* | Merge pull request #13811 from flouthoc/container_inspect_entrypointOpenShift Merge Robot2022-04-08
|\ \ | | | | | | container,inspect: convert `Entrypoint` to an array instead of a string
| * | container,inspect: convert Entrypoint to array instead of a stringAditya R2022-04-08
| | | | | | | | | | | | | | | | | | | | | Convert container entrypoint from string to an array inorder to make sure there is parity between `podman inspect` and `docker inspect` Signed-off-by: Aditya R <arajan@redhat.com>
* | | Merge pull request #13687 from rhatdan/VENDOROpenShift Merge Robot2022-04-08
|\ \ \ | |/ / |/| | Vendor in new opencontainers/selinux
| * | Vendor in new opencontainers/selinuxDaniel J Walsh2022-04-08
| |/ | | | | | | | | | | | | | | Also update vendor of containers/common,buildah,storage,image Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2069586 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* / images --sizeValentin Rothberg2022-04-08
|/ | | | | | | | | | Add a --size option to podman images to allow for disabling computing the size of listed images. If listing images is critical to performance, user may chose to turn off size computation to speed things up. Context: #13755 Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* Merge pull request #13696 from Luap99/apiv2-netavarkOpenShift Merge Robot2022-04-04
|\ | | | | test/apiv2: support netavark
| * test/apiv2: support netavarkPaul Holzinger2022-03-30
| | | | | | | | | | | | | | | | | | | | | | Since netavark does not support dhcp yet we have to create a macvlan network with a static subnet. Since we do not use the network to run containers the actual subnet does not matter. Also stop hard coding the network id. Unlike the cni backend the netavark backend creates random ids that are not predictable. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* | Merge pull request #13490 from gcalin/13266OpenShift Merge Robot2022-04-04
|\ \ | | | | | | pod logs enhancements: option to color logs
| * | Add option for pod logs to display different colors per container.gcalin2022-03-29
| |/ | | | | | | | | Signed-off-by: Krzysztof Baran <krysbaran@gmail.com> Signed-off-by: gcalin <caling@protonmail.com>
* | Merge pull request #13765 from giuseppe/do-not-set-oom-score-adjOpenShift Merge Robot2022-04-04
|\ \ | | | | | | specgen: do not set OOMScoreAdj by default