summaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
* chrootuser: default to GID 0 when given a numeric --userNalin Dahyabhai2018-05-17
| | | | | | | | | | | | | | | When we're given a numeric --user value, default to GID 0 if the numeric ID doesn't correspond to a user entry in /etc/passwd that can provide us with the user's primary group ID. Make sure that GetAdditionalGroupsForUser() returns wrapped errors. Also test various user:group forms. Signed-off-by: Nalin Dahyabhai <nalin@redhat.com> Closes: #728 Approved by: mheon
* Remove old varlink testsJhon Honce2018-05-16
| | | | | | | | | * Replaced by tests in libpod/contrib/python/test Signed-off-by: Jhon Honce <jhonce@redhat.com> Closes: #766 Approved by: rhatdan
* Allow push/save without image referenceumohnani82018-05-16
| | | | | | | | | | | | If the user uses the image ID when saving to either docker-archive or oci-archive, then do not save a reference in the manifest/index.json. If the user chooses to push without an image reference, i.e <transport>:<path> it should be valid and succeed. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #782 Approved by: rhatdan
* Remove stop on error from Docker install switch in baseline testsTomSweeneyRedHat2018-05-14
| | | | | | | Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com> Closes: #760 Approved by: mheon
* Skip systemd-style CGroups testMatthew Heon2018-05-11
| | | | | | | | | | Until we get Systemd cgroup manager working, this will cause a validation error. Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #507 Approved by: baude
* test/e2e/run_userns_test.go: new fileGiuseppe Scrivano2018-05-04
| | | | | | | Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com> Closes: #690 Approved by: mheon
* podman should assign a host port to -p when omittedbaude2018-05-01
| | | | | | | | | | | If the user does not provide a host port when adding -p to create/run, podman should inject an available random port. podman run -p 80 .... podman should assign a random port to the host and expose the container port 80 to it Signed-off-by: baude <bbaude@redhat.com> Closes: #703 Approved by: rhatdan
* do not commit default volumes from containerbaude2018-04-30
| | | | | | | | | | | when performing a container commit, we should not add the default list of volumes for a container to the resulting image. it will cause the resulting image to crash when run subsequently. Signed-off-by: baude <bbaude@redhat.com> Closes: #699 Approved by: mheon
* Make ':' a restricted character for file namesumohnani82018-04-30
| | | | | | | | | | | file names for podman load, save, export, and import cannot contain ":" in them. It is a reserved character for parsing filenames. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #694 Approved by: rhatdan
* Use buildah commit and bud in podmanbaude2018-04-27
| | | | | | | | | | | Vendor in buildah and use as much of commit and bug as possible for podman build and commit. Resolves #586 Signed-off-by: baude <bbaude@redhat.com> Closes: #681 Approved by: mheon
* Remove systemd-cat supportJhon Honce2018-04-27
| | | | | | | | | - CI does not support systemd-cat Signed-off-by: Jhon Honce <jhonce@redhat.com> Closes: #683 Approved by: rhatdan
* Refactor unittest for varlink componentJhon Honce2018-04-27
| | | | | | | | | | | | - Allow unittest's to run as normal user - Refactor tests to use unittest features - Refactor tests to use fixtures to track resources - Update test runner script to clean up on failure Signed-off-by: Jhon Honce <jhonce@redhat.com> Closes: #683 Approved by: rhatdan
* Add --default-mounts-file hidden flagumohnani82018-04-26
| | | | | | | | | | | The hidden flag is used to override the path of the default mounts file for testing purposes. Also modified the secrets pkg to allow for this override to happen. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #678 Approved by: mheon
* Modify --user flag for podman create and runumohnani82018-04-24
| | | | | | | | | | If an integer is passed into the --user flag, i.e --user=1234 don't look up the user in /etc/passwd, just assign the integer as the uid. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #652 Approved by: mheon
* Add some podman search test with filterYiqiao Pu2018-04-24
| | | | | | | | | Add search test with filter stars, is-automated and is-official. Signed-off-by: Yiqiao Pu <ypu@redhat.com> Closes: #662 Approved by: rhatdan
* Fix podman search no-trunc testYiqiao Pu2018-04-24
| | | | | | | | | | Add --no-trunc to the command line and add output check for the lines not include "..." with this flag. Signed-off-by: Yiqiao Pu <ypu@redhat.com> Closes: #662 Approved by: rhatdan
* Merge pull request #647 from umohnani8/secretsDaniel J Walsh2018-04-23
|\ | | | | Add FIPS mode secret
| * Add FIPS mode secretumohnani82018-04-23
| | | | | | | | | | | | | | | | If the host is in FIPS mode and /etc/system-fips exists /run/secrets/system-fips is created in the container so that the container can run in FIPS mode as well. Signed-off-by: umohnani8 <umohnani@redhat.com>
* | Merge pull request #656 from ypu/restart_testDaniel J Walsh2018-04-23
|\ \ | |/ |/| Restart test Improve
| * Add restart test with timeoutYiqiao Pu2018-04-23
| | | | | | | | | | | | | | | | | | | | | | | | Test the --timeout flag with a container which can not be stopped with SIGSTOP. This means the container should can not be stopped and will be killed then restart with timeout value. Test steps: Start a container with STOPSIGNAL=SIGKILL Restart it with --timeout set to 2s Check the restart command will finished more than 2s and less than 10s(the default timeout) Signed-off-by: Yiqiao Pu <ypu@redhat.com>
| * Improve restart latest container testYiqiao Pu2018-04-23
| | | | | | | | | | | | | | | | | | | | | | | | Remove the --latest from the restart running container test, and add a separated case with following steps: start two container in order: test1, test2 restart container with --latest check the start time for test1 and test2 And the results should be test1 is not restarted and test2 is restarted. Signed-off-by: Yiqiao Pu <ypu@redhat.com>
| * Add start time check for restart testYiqiao Pu2018-04-23
| | | | | | | | | | | | Check the start time changed after restart the container. Signed-off-by: Yiqiao Pu <ypu@redhat.com>
* | Initial varlink implementationbaude2018-04-23
|/ | | | | | | Signed-off-by: baude <bbaude@redhat.com> Closes: #627 Approved by: mheon
* enable no test cachebaude2018-04-21
| | | | | | | | | | | | | been meaning to do this for a while. add an environment variable that disables the caching and restoring of images before integration tests are run. this is useful for developers only ... when testing specific integration tests where caching and restoring the images is not worth the benefit. Signed-off-by: baude <bbaude@redhat.com> Closes: #650 Approved by: rhatdan
* Fix tests for podman run --attachMatthew Heon2018-04-19
| | | | | | | | | | When STDOUT and STDERR are not attached, we now print a container ID. Make the tests aware of this. Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #638 Approved by: rhatdan
* Add one test case for check diff in container and committed imageYiqiao Pu2018-04-19
| | | | | | | | | | | | | The test steps are: 1. Start a container and touch a file under /tmp 2. Use diff to check the container 3. commit the change into a new image 4. Use diff to check the image Signed-off-by: Yiqiao Pu <ypu@redhat.com> Closes: #643 Approved by: mheon
* Vendor in latest containers/image and contaners/storageumohnani82018-04-19
| | | | | | | | | Made necessary changes to functions to include contex.Context wherever needed Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #640 Approved by: baude
* Fix a typoYiqiao Pu2018-04-19
| | | | | | | | | Update LineInOuputContains to LineInOutputContains. Signed-off-by: Yiqiao Pu <ypu@redhat.com> Closes: #642 Approved by: rhatdan
* ip validation game too strongNathan Williams2018-04-18
| | | | | | | Signed-off-by: Nathan Williams <nath.e.will@gmail.com> Closes: #635 Approved by: rhatdan
* - reverse host field order (ip goes first)Nathan Williams2018-04-18
| | | | | | | | | - fix host string split to permit IPv6 Signed-off-by: Nathan Williams <nath.e.will@gmail.com> Closes: #635 Approved by: rhatdan
* Add a function for check if command existYiqiao Pu2018-04-16
| | | | | | | Use this function to check if command exist before execute it in our test. Signed-off-by: Yiqiao Pu <ypu@redhat.com>
* Add WaitContainerReady for wait for docker registry readyYiqiao Pu2018-04-16
| | | | | | | | | | Sometime podman push local registry still failed caused by the docker registry is not start yet after sleep 5s in the test. So add this function to check the container status by its output and skip the test when the docker registry can not start normally instead of failed the case. Signed-off-by: Yiqiao Pu <ypu@redhat.com>
* Add several podman push testsYiqiao Pu2018-04-16
| | | | | | | | | | | Add five tests for podman push tests: - push to docker with authorization - push to docker-archive - push to docker-daemon - push to oci-archive - push to ostree Signed-off-by: Yiqiao Pu <ypu@redhat.com>
* Allow the use of -i/-a on any containerbaude2018-04-14
| | | | | | | | | | | | | We used to not allow the use of -a/-i on containers that were not started with -i or a tty. Given the improvements in our terminal handling, this should work now. This also fixes a systemic problem with the autotests. Signed-off-by: baude <bbaude@redhat.com> Closes: #617 Approved by: baude
* Fix secrets patchumohnani82018-04-13
| | | | | | | | | | | The secrets code was just tarring and copying the contents of the secrets directory on host as is. This meant it was not accounting for any symlinks inside the directory, leading up to the contents not being copied over. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #611 Approved by: mheon
* Remove demos.sh file from testumohnani82018-04-13
| | | | | | | | | I must have accidentally added this extra file in one of my older PRs. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #611 Approved by: mheon
* Fix podman run --attach testsMatthew Heon2018-04-13
| | | | | | | Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #608 Approved by: baude
* Add tests for podman attachMatthew Heon2018-04-13
| | | | | | | Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #608 Approved by: baude
* HACK temporary fix for test suiteMatthew Heon2018-04-13
| | | | | | | | | | | | | We leak open files when creating new c/storage stores (locks do not close themselves, so the open FDs in the test suite increase every time we use c/storage to load cached images for the tests). Fix this temporarily by increasing rlimits on open files until we can create a permanent fix next release. Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #615 Approved by: baude
* Fix leaking files in GinkgoMatthew Heon2018-04-13
| | | | | | | Signed-off-by: Matthew Heon <mheon@redhat.com> Closes: #612 Approved by: rhatdan
* Functionality changes to the following flagsumohnani82018-04-06
| | | | | | | | | | | | | | | | | | | --group-add --blkio-weight-device --device-read-bps --device-write-bps --device-read-iops --device-write-iops --group-add now supports group names as well as the gid associated with them. All the --device flags work now with moderate changes to the code to support both bps and iops. Added tests for all the flags. Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #590 Approved by: mheon
* Add hooks support to podmanDaniel J Walsh2018-04-05
| | | | | | | Signed-off-by: Daniel J Walsh <dwalsh@redhat.com> Closes: #155 Approved by: mheon
* Only allocate tty when -tbaude2018-04-03
| | | | | | | | | | | In our ezrly development, we always allocated a tty when not -d. Now we should only allocated when the user asks for it. Resolves: #573 Signed-off-by: baude <bbaude@redhat.com> Closes: #574 Approved by: rhatdan
* Vendor in latest containers/imageDaniel J Walsh2018-04-03
| | | | | | | | | | | | | | | | | | | | | | | | | Some more features. docker-archive generates docker legacy compatible images Do not create $DiffID subdirectories for layers with no configs Ensure the layer IDs in legacy docker/tarfile metadata are unique docker-archive: repeated layers are symlinked in the tar file sysregistries: remove all trailing slashes Improve docker/* error messages Fix failure to make auth directory Create a new slice in Schema1.UpdateLayerInfos Drop unused storageImageDestination.{image,systemContext} Load a *storage.Image only once in storageImageSource Support gzip for docker-archive files Remove .tar extension from blob and config file names ostree, src: support copy of compressed layers ostree: re-pull layer if it misses uncompressed_digest|uncompressed_size image: fix docker schema v1 -> OCI conversion Add /etc/containers/certs.d as default certs directory Signed-off-by: Daniel J Walsh <dwalsh@redhat.com> Closes: #569 Approved by: mheon
* Sleep for 5 seconds before pushing to registry in testsTomSweeneyRedHat2018-04-02
| | | | | | | Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com> Closes: #576 Approved by: rhatdan
* Eliminate raceyness of sig-proxy testbaude2018-03-30
| | | | | | | | | | Use a socket to coordinate between the test suite and the container and its script. Signed-off-by: baude <bbaude@redhat.com> Closes: #567 Approved by: rhatdan
* Allow sha256: prefix for inputbaude2018-03-29
| | | | | | | | | | | | We should allow users to pass in image ids with the sha256: prefix for local images. Resolves: #493 Signed-off-by: baude <bbaude@redhat.com> Closes: #560 Approved by: baude
* Add secrets patch to podmanumohnani82018-03-29
| | | | | | | | | | Adds support for mounting secrets especially on RHEL where the container can use the host subsription to run yum Signed-off-by: umohnani8 <umohnani@redhat.com> Closes: #544 Approved by: rhatdan
* Disable --sig-proxy tests due to race conditionsMatthew Heon2018-03-28
| | | | | | | Signed-off-by: Matthew Heon <mheon@redhat.com> Closes: #564 Approved by: rhatdan
* podman exec should handle options --env fooDaniel J Walsh2018-03-26
| | | | | | | | | | | | | If the user does not specify foo=bar, then the exec code should look for the foo environment variable in its environment and pass it in. This is the way podman run works. Also added tests to make sure this all works. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com> Closes: #552 Approved by: mheon