Commit graph

32 commits

Author SHA1 Message Date
baude 8dfebd4607 varlink containers
first pass at adding in the container related endpoints/methods for the libpod
backend. Couple of important notes:

* endpoints that can use a console are not going to be done until we have "remote" console
* several of the container methods should probably be able to stream as opposed to a one-off return

Signed-off-by: baude <bbaude@redhat.com>

Closes: #708
Approved by: baude
2018-05-03 17:31:33 +00:00
baude 86e0c87a29 fix typos in the inspect json structs
Resolves: #633

Signed-off-by: baude <bbaude@redhat.com>

Closes: #710
Approved by: rhatdan
2018-05-02 18:02:22 +00:00
baude 7a0a8552cb Fix misc stuff found by jhonce
During the python client implementation, jhonce found some return types
that needed correction as well as a panic related to history which is now
corrected.

Signed-off-by: baude <bbaude@redhat.com>

Closes: #704
Approved by: rhatdan
2018-04-30 22:22:08 +00:00
baude a824186ac9 Use buildah commit and bud in podman
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
2018-04-27 20:51:07 +00:00
umohnani8 51a5cdc636 Modify secrets pkg
Made a mistake in my earlier patch. I though that if you add an empty string
to an array, the length of the array would still be 0...
Realised this when vendoring the secrets pkg into cri-o.

Signed-off-by: umohnani8 <umohnani@redhat.com>

Closes: #685
Approved by: mheon
2018-04-27 14:07:54 +00:00
baude 39a7a773a6 varlink images
implement varlink image functions for working with libpod with the exception of a
couple due to incompletions on the libpod side of things (build).

also, created a first pass at a libpodpy package which will stand as a client to
working with libpod's varlink methods using python.

Signed-off-by: baude <bbaude@redhat.com>

Closes: #669
Approved by: baude
2018-04-26 19:14:44 +00:00
Matthew Heon 0ccfd7dc20 Retrieve IP addresses for container from DB
Instead of execing out to the host's IP, use the IP address we
got back from CNI to populate Inspect's IP address information.

Signed-off-by: Matthew Heon <mheon@redhat.com>

Closes: #680
Approved by: umohnani8
2018-04-26 17:26:13 +00:00
umohnani8 6ac8a24db4 Add --default-mounts-file hidden flag
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
2018-04-26 16:33:25 +00:00
umohnani8 cf41dc70b3 Modify --user flag for podman create and run
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
2018-04-24 14:28:33 +00:00
umohnani8 57afb7514d Add FIPS mode secret
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>
2018-04-23 13:17:12 -04:00
baude 8493dba23c Initial varlink implementation
Signed-off-by: baude <bbaude@redhat.com>

Closes: #627
Approved by: mheon
2018-04-23 14:29:45 +00:00
baude 313e5e83e9 regression: tls verify should be set on registries.conf if insecure
In the case where podman needs to pull an image, if that registry that the image
resides on is known to be insesure (as defined in /etc/containers/registries.conf),
tls-verify should be altered on the fly.

Signed-off-by: baude <bbaude@redhat.com>

Closes: #626
Approved by: mheon
2018-04-18 14:07:59 +00:00
umohnani8 9aafc25a3d Fix secrets patch
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
2018-04-13 21:25:15 +00:00
umohnani8 998fd2ece0 Functionality changes to the following flags
--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
2018-04-06 00:09:46 +00:00
Daniel J Walsh fdcf633a33 Add hooks support to podman
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>

Closes: #155
Approved by: mheon
2018-04-05 14:13:49 +00:00
Matthew Heon 0fb38659b7 Add container dependencies to Inspect output
Signed-off-by: Matthew Heon <matthew.heon@gmail.com>

Closes: #577
Approved by: rhatdan
2018-04-03 14:57:16 +00:00
Nalin Dahyabhai 94301bab8f Correct a godoc comment
Correct the names of the files in the godoc for
pkg/chrootuser/GetUser().

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>

Closes: #579
Approved by: rhatdan
2018-04-02 20:03:17 +00:00
umohnani8 8a96b4acbc Add secrets patch to podman
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
2018-03-29 14:15:27 +00:00
baude 9aba605dde Remove dependency on kubernetes
podman parse and attach were using a very small portion of the kubernetes code
but using it caused a signficant increase in binary size.

Signed-off-by: baude <bbaude@redhat.com>

Closes: #559
Approved by: rhatdan
2018-03-27 21:55:33 +00:00
baude b85b217f55 Stage3 Image Library
This represents the stage3 implementation for the image library.  At this point, we
are moving the image-centric functions to pkg/image including migration of args and
object-oriented references.  This is a not a one-for-one migration of funcs and some
funcs will need to continue to reside in runtime_img as they are overly specific to
libpod and probably not useful to others.

Signed-off-by: baude <bbaude@redhat.com>

Closes: #484
Approved by: baude
2018-03-14 20:21:31 +00:00
baude bc358eb396 Include tmpfs in inspect
Other container runtimes include the tmpfs mount points in their inspect
output.  Podman should as well.  It is under hostconfig.

Resolves: #483

Signed-off-by: baude <bbaude@redhat.com>

Closes: #488
Approved by: rhatdan
2018-03-14 17:14:07 +00:00
baude 4929e37507 Performance enhancement for podman images
Previous code was using slow routines to collect some of the information
needed to output images.  Specifically size was being calculated instead
of using the cached, already known size already available.  Also, straight-
lined several of the code paths.  Overall assessment is that these
improvements cut the time for images in half.

Signed-off-by: baude <bbaude@redhat.com>

Closes: #365
Approved by: mheon
2018-02-20 21:54:32 +00:00
Daniel J Walsh 2e96acf300 Change json to match docker inspect
Changing these fields caused the output of podman inspect to more
closely match docker inspect.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>

Closes: #306
Approved by: mheon
2018-02-11 11:50:34 +00:00
Daniel J Walsh 588c9bb5de
Merge pull request #289 from TomSweeneyRedHat/dev/tsweeney/username
Change un/pwd handling to match Buildah's
2018-02-07 14:07:54 -05:00
umohnani8 367213a394 Match podman inspect output to docker inspect
Made a change to make sure that the output paths of podman inspect
matches that of docker inspect. For example to get the stop signal
you should be able to do podman inspect ctr --format {{.Config.StopSignal}}
and the same thing in docker will give the same results.

Signed-off-by: umohnani8 <umohnani@redhat.com>

Closes: #292
Approved by: rhatdan
2018-02-06 19:31:55 +00:00
TomSweeneyRedHat bb37c11651 Change un/pwd handling to match Buildah's
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2018-02-06 09:29:23 -05:00
baude 6ba6ecf59b Migrate Create|Commit to ginkgo
Migrate create and commit bats tests to the ginkgo
test suite.  In doing so, some structures had to be
moved to pkg/podmanstructs/podmanstructs.go so we
could do better verification of test results.

Signed-off-by: baude <bbaude@redhat.com>

Closes: #286
Approved by: rhatdan
2018-02-02 22:44:40 +00:00
Matthew Heon 0e52d43962 Remove unused pkg/storage code
This code was refactored into libpod, so no need to keep the old
version around

Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
2018-01-11 18:44:05 -05:00
Daniel J Walsh 00d38cb379 podman create/run need to load information from the image
We should be pulling information out of the image to set the
defaults to use when setting up the container.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>

Closes: #110
Approved by: mheon
2018-01-03 12:38:18 +00:00
umohnani8 eaf4d6c8c2 Vendor in latest upstream containers/image
Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-12-11 09:51:34 -05:00
baude d2eda1a864 Enhancements to papr tests
The PR contains several enhancements to our CI testing.

- enable lint testing on Fedora
- add Centos Atomic as test platform
- integration tests on run on the OS natively (uncontainerized)
- builds are done in containers
- inclusion of Vagrant file for local testing

Signed-off-by: baude <bbaude@redhat.com>

Closes: #18
Approved by: mheon
2017-11-17 02:07:18 +00:00
Matthew Heon a031b83a09 Initial checkin from CRI-O repo
Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
2017-11-01 11:24:59 -04:00