Commit Graph

795 Commits

Author SHA1 Message Date
OpenShift Merge Robot 79039dd24e Merge pull request #438 from jwhonce/issues/8773
Updated report.template to be more compatible
2021-02-05 06:52:46 -05:00
Jhon Honce df0bf9adef Updated report.template to handle newlines
Previous code and tests did not reflect actual users input and expected
output.

Add remaining compatibilty golang template funcs

- json
- pad
- truncate

https://bugzilla.redhat.com/show_bug.cgi?id=1922077
Fixes #8702

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2021-02-04 14:13:44 -07:00
OpenShift Merge Robot f118741788 Merge pull request #434 from containers/dependabot/go_modules/github.com/containers/storage-1.25.0
Bump github.com/containers/storage from 1.24.5 to 1.25.0
2021-02-04 15:28:45 -05:00
dependabot-preview[bot] 4ab2941105 Bump github.com/containers/storage from 1.24.5 to 1.25.0
Bumps [github.com/containers/storage](https://github.com/containers/storage) from 1.24.5 to 1.25.0.
- [Release notes](https://github.com/containers/storage/releases)
- [Changelog](https://github.com/containers/storage/blob/master/docs/containers-storage-changes.md)
- [Commits](https://github.com/containers/storage/compare/v1.24.5...v1.25.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-02-04 05:09:54 -05:00
OpenShift Merge Robot 777f6b7f61 Merge pull request #432 from containers/dependabot/go_modules/github.com/onsi/ginkgo-1.15.0
Bump github.com/onsi/ginkgo from 1.14.2 to 1.15.0
2021-02-03 09:51:43 -05:00
Daniel J Walsh 54a7f71e17 Bump github.com/onsi/ginkgo from 1.14.2 to 1.15.0
Bumps [github.com/onsi/ginkgo](https://github.com/onsi/ginkgo) from 1.14.2 to 1.15.0.
- [Release notes](https://github.com/onsi/ginkgo/releases)
- [Changelog](https://github.com/onsi/ginkgo/blob/master/CHANGELOG.md)
- [Commits](https://github.com/onsi/ginkgo/compare/v1.14.2...v1.15.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-02-03 06:29:02 -05:00
OpenShift Merge Robot 8b73d0e178 Merge pull request #431 from containers/dependabot/go_modules/github.com/onsi/gomega-1.10.5
Bump github.com/onsi/gomega from 1.10.4 to 1.10.5
2021-02-02 09:39:51 -05:00
dependabot-preview[bot] f3cccebace Bump github.com/onsi/gomega from 1.10.4 to 1.10.5
Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.10.4 to 1.10.5.
- [Release notes](https://github.com/onsi/gomega/releases)
- [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md)
- [Commits](https://github.com/onsi/gomega/compare/v1.10.4...v1.10.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-02-02 06:12:56 -05:00
Daniel J Walsh 3c89b4584b Merge pull request #428 from rhatdan/VENDOR
Bump to v0.34.0
2021-02-01 13:17:04 -05:00
Daniel J Walsh 083b14e0c4 Move to v0.34.1-dev
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-02-01 11:10:05 -05:00
Daniel J Walsh 5c355211bc Bump to v0.34.0
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-02-01 11:09:43 -05:00
OpenShift Merge Robot ef8db8fbb2 Merge pull request #424 from rhatdan/format
Add image_default_format
2021-02-01 11:06:42 -05:00
Daniel J Walsh 0f802d0065 Add image_default_format
Currently when pulling/pushing images we default to the format
of the source image.  When Building images we default to OCI.

Customers have asked us to allow them to force a specific image
type when pushing to a registry.

We already have a flag to building images.

This PR adds image_default_format to define the format to be used
by all tools create/building/pulling and pusing images.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-02-01 06:38:50 -05:00
OpenShift Merge Robot c4e3a67c88 Merge pull request #427 from rhatdan/journald
Change default log driver to journald
2021-02-01 06:37:54 -05:00
OpenShift Merge Robot 81ee30d1ad Merge pull request #426 from jwhonce/issues/8773
Add compatible template functions
2021-02-01 05:42:52 -05:00
Daniel J Walsh 451f5fb68b Change default log driver to journald
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-30 07:57:07 -05:00
Jhon Honce 89c438e1ea Add compatible template functions
"join":  strings.Join,
  "lower": strings.ToLower,
  "split": strings.Split,
  "title": strings.Title,
  "upper": strings.ToUpper,

Add and update tests to exercise these additions.
Update go doc with details of usage.

Fixes #8773
Closes https://bugzilla.redhat.com/show_bug.cgi?id=1915383

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2021-01-29 14:07:19 -07:00
OpenShift Merge Robot f35a6db1d0 Merge pull request #420 from EduardoVega/add-U-volume-flag
Add U volume flag to chown source volumes
2021-01-29 14:08:18 -05:00
Eduardo Vega f78dc39440 Add U volume flag and chown pkg
Signed-off-by: Eduardo Vega <edvegavalerio@gmail.com>
2021-01-29 10:57:49 -06:00
OpenShift Merge Robot 5985c400ca Merge pull request #425 from containers/dependabot/go_modules/github.com/containers/image/v5-5.10.1
Bump github.com/containers/image/v5 from 5.10.0 to 5.10.1
2021-01-29 09:18:48 -05:00
dependabot-preview[bot] 175d0da52e Bump github.com/containers/image/v5 from 5.10.0 to 5.10.1
Bumps [github.com/containers/image/v5](https://github.com/containers/image) from 5.10.0 to 5.10.1.
- [Release notes](https://github.com/containers/image/releases)
- [Commits](https://github.com/containers/image/compare/v5.10.0...v5.10.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-29 07:55:26 -05:00
OpenShift Merge Robot 416fc4fa4e Merge pull request #421 from cyphar/seccomp-update
seccomp: various updates
2021-01-28 15:14:26 -05:00
OpenShift Merge Robot 629d05bbae Merge pull request #422 from giuseppe/check-ownership-xdg-runtime-dir
pkg: check ownership for XDG_RUNTIME_DIR
2021-01-28 14:02:30 -05:00
OpenShift Merge Robot 412704514c Merge pull request #423 from containers/dependabot/go_modules/github.com/containers/image/v5-5.10.0
Bump github.com/containers/image/v5 from 5.9.0 to 5.10.0
2021-01-28 14:01:32 -05:00
dependabot-preview[bot] 5a42e777e5 Bump github.com/containers/image/v5 from 5.9.0 to 5.10.0
Bumps [github.com/containers/image/v5](https://github.com/containers/image) from 5.9.0 to 5.10.0.
- [Release notes](https://github.com/containers/image/releases)
- [Commits](https://github.com/containers/image/compare/v5.9.0...v5.10.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2021-01-28 11:53:10 +01:00
Giuseppe Scrivano 70fd91a3bb pkg: check ownership for XDG_RUNTIME_DIR
check whether the user owns the specified XDG_RUNTIME_DIR.  Hopefully
it will help catching errors when running in a "sudo -u" session that
uses the wrong value for XDG_RUNTIME_DIR.

Closes: https://github.com/containers/podman/issues/9114

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2021-01-28 10:11:51 +01:00
Aleksa Sarai 1478f9331d seccomp: update profile to Linux 5.11 list
This mirrors the Docker and containerd changes, with the caveat that
because mount(2) is permitted under podman for all containers we
therefore add all of the v2 mount API syscalls as available to all
containers.

Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
2021-01-27 21:40:48 +11:00
Aleksa Sarai 4e485f45ab seccomp: add CI check for up-to-date seccomp.json
Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
2021-01-27 21:40:45 +11:00
Aleksa Sarai 1195c8bb0b seccomp: re-add generation script
The generate.go script used to fill the default seccomp profile file is
quite important as otherwise distributions will end up having outdated
seccomp filters even after a podman update.

This script comes from the Docker repo.

Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
2021-01-27 21:40:42 +11:00
Aleksa Sarai 624d0aa703 seccomp: deduplicate default profile
Several syscalls were enabled globally (SCMP_ACT_ALLOW without any
conditions for all containers), but also had conditional rules later in
the profile (likely inherited from Docker). The following syscalls do
not need special casing because they were globally enabled:

 * clone, unshare, mount, umount, umount2 all had special CAP_SYS_ADMIN
   restrictions but those don't make sense since they were also enabled
   for all containers.
 * reboot was permitted for CAP_SYS_BOOT and all containers.
 * name_to_handle_at was permitted for CAP_SYS_ADMIN, CAP_SYS_NICE(?),
   and all containers.

And certain syscalls had globally-enabled rules when they shouldn't
have:

 * socket has special rules for CAP_AUDIT_WRITE but it also had a global
   "allow unconditionally" rule. It turns out that libseccomp will
   override unconditional rules with conditional ones but this is
   somewhat of an implementation detail and it's much safer to remove
   the rule and use the existing cases.

Now the only syscalls remaining with complicated rules (meaning they
appear more than once in the profile) are:

 * sync_file_range2 which is architecture specific (though in principle
   we could move it to enabled-without-rules because runc ignores
   unknown syscalls).

Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
2021-01-27 21:39:54 +11:00
OpenShift Merge Robot 422eb91f40 Merge pull request #415 from rhatdan/pulls
Add image_parallel_copies engine config
2021-01-21 17:49:29 -05:00
Daniel J Walsh 952d2c9991 Add image_parallel_copies engine config
This will allow users to configure the amount of parallel copies that
the container engines are allowed to do. This allows users to configure
their systems to match their available network settings.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-21 14:59:34 -05:00
OpenShift Merge Robot ab2c85a60c Merge pull request #416 from ashley-cui/nameprefix
Fix secret create prefix
2021-01-21 14:15:02 -05:00
Ashley Cui 2aecd17ed8 Fix secret create prefix
Fix a bug where if the secret name was a prefix of an existing id, secrets would reject the new name
Now, you can use the secret name as expected

Example: if a secret with id "abcdefg" already exists:
Previously, it would error if you tried to create a secret with name "abc"
Now it allows you to do so

Signed-off-by: Ashley Cui <acui@redhat.com>
2021-01-20 08:25:48 -05:00
OpenShift Merge Robot e11260664d Merge pull request #418 from giuseppe/fix-duplicated-wording
cgroupv2: fix typo in comment
2021-01-20 05:10:48 -05:00
Giuseppe Scrivano 8f15d23f10 cgroupv2: fix typo in comment
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2021-01-20 09:44:05 +01:00
OpenShift Merge Robot 767d30bb38 Merge pull request #417 from baude/logdriver
Add accessor for log-driver
2021-01-19 16:47:26 -05:00
OpenShift Merge Robot 8fedf17690 Merge pull request #414 from ashley-cui/secretfix
Fix secret name validation
2021-01-19 16:38:27 -05:00
baude c0b1b9a368 Add accessor for log-driver
For podman, we need to be able to get the log driver from common config.

Signed-off-by: baude <bbaude@redhat.com>
2021-01-19 15:08:34 -06:00
Ashley Cui f9ab37eef1 Fix secret name validation
Secret names should not end with "."

Signed-off-by: Ashley Cui <acui@redhat.com>
2021-01-19 12:10:42 -05:00
OpenShift Merge Robot ee5a996bd2 Merge pull request #413 from ashley-cui/secretfix
Fix name validation and dir mode in secrets
2021-01-19 11:52:59 -05:00
Ashley Cui ce15873c3c Fix name validation and dir mode in secrets
fix name validation to reject secret names that end with "-"
Create filedriver dir with proper permissions

Signed-off-by: Ashley Cui <acui@redhat.com>
2021-01-19 09:06:03 -05:00
OpenShift Merge Robot ca15b1879d Merge pull request #410 from containers/dependabot/go_modules/github.com/stretchr/testify-1.7.0
Bump github.com/stretchr/testify from 1.6.1 to 1.7.0
2021-01-15 20:50:39 -05:00
dependabot-preview[bot] a9b4d39f85 Bump github.com/stretchr/testify from 1.6.1 to 1.7.0
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.6.1 to 1.7.0.
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.6.1...v1.7.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-15 04:37:03 -05:00
Daniel J Walsh 012d143d27 Merge pull request #407 from naveensrinivasan/fix/osx-make-386
fix - make target all on osx
2021-01-13 10:14:23 -05:00
Daniel J Walsh 2a0c50a82a Merge pull request #408 from giuseppe/fix-key-name
config: fix runtime_supports_nocgroup key name
2021-01-13 10:14:09 -05:00
Giuseppe Scrivano 52dd8b2d67 config: fix runtime_supports_nocgroup key name
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2021-01-13 15:11:54 +01:00
OpenShift Merge Robot b6b00d4850 Merge pull request #405 from ashley-cui/secretfix
Fix secret name regex
2021-01-12 13:46:38 -05:00
naveen 69afcc3574 fix - make target all on osx
Fixes the make target all on osx.
2021-01-12 13:46:02 -05:00
Ashley Cui eb63fb2ef2 Fix secret name regex
Fix secret name regex to take one character secret names

Signed-off-by: Ashley Cui <acui@redhat.com>
2021-01-12 13:04:45 -05:00