Commit graph

39 commits

Author SHA1 Message Date
Valentin Rothberg c0bf0ba9e5 podman build --pull: refine help message and docs
Refine and correct the wording of the `--pull` flag in the help message
and the docs.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2021-01-28 18:00:22 +01:00
Ed Santiago 37abec240a [CI:DOCS] fix go-md2man HTMLSpan warnings
I'm tired of seeing these every time I run 'make':

   WARNING: go-md2man does not handle node type HTMLSpan

Cause: left-angle-brackets ( < ) in document source

Solution:
  1) backquote-escape those that need to be shown, usually
     ones referring to an argument or email address; or
  2) Actual HTML ( <sup> and <a> ) which are meant to be
     shown in generated HTML docs but can't be shown in
     man pages, we filter out via a sed expression.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2021-01-19 12:59:03 -07:00
Daniel J Walsh c88022589a
Bump to containers/buildah 1.9.2
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-15 06:23:19 -05:00
Daniel J Walsh 3d453f9d2e
podman build --force-rm defaults to true in code
The man page and code should match for what is the default settings.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-10 05:52:33 -05:00
Daniel J Walsh d9ebbbfe5b
Switch references of /var/run -> /run
Systemd is now complaining or mentioning /var/run as a legacy directory.
It has been many years where /var/run is a symlink to /run on all
most distributions, make the change to the default.

Partial fix for https://github.com/containers/podman/issues/8369

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-01-07 05:37:24 -05:00
Josh Soref 4fa1fce930 Spelling
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-12-22 13:34:31 -05:00
Daniel J Walsh 20160af018
Switch from pkg/secrets to pkg/subscriptions
The buildah/pkg/secrts package was move to
containers/common/pkg/subscriptions.
Switch to using this by default.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-11-26 07:30:18 -05:00
OpenShift Merge Robot 738d62ea96
Merge pull request #7964 from vrothberg/shortnames
short-name aliasing
2020-11-13 18:28:17 +01:00
OpenShift Merge Robot 6d9d9fee30
Merge pull request #8326 from Luap99/fix-build-namespace
Fix namespace flag parsing for podman build
2020-11-13 16:44:45 +01:00
Valentin Rothberg 8e4a42aa42 short-name aliasing
Add support for short-name aliasing.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-11-13 15:40:06 +01:00
TomSweeneyRedHat 6ea13fd872 Change podman build --pull=true to PullIfMissing
One last tweak to the man page for 'build --pull' and after
further testing against Docker, one slight change to the
pull policy.  First I changed `--pull=false` from PullNever
to PullIfMissing.  This matches Docker and will pull the
image if it's not present rather than erroring.  We've
the `--pull-never` option if someone wants the pull to
not do an actual pull and to error if the image isn't
local.

Then for the man page, I'd a much bigger change, in the
initial PR, I've backed most of that out and just
added a tweak.

Hopefully this puts this portion of the pull work behind
us for a while.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2020-11-12 18:50:31 -05:00
OpenShift Merge Robot 2fc2d4643e
Merge pull request #8316 from rhatdan/codespell
Fix issues found with codespell
2020-11-12 23:29:51 +01:00
Paul Holzinger 79f5aed316 Add podman build --net alias for --network
Fixes #8332

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-11-12 23:17:42 +01:00
Paul Holzinger f5a2e578eb Maintain consistent order of short and long flag names in docs
Make the order of short and long flag names in the documentation
consistent. Also adjust the man page validaten script to only allow
the `**--long**, **-s**` syntax.

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-11-12 21:46:17 +01:00
Daniel J Walsh a7431003b8
Fix issues found with codespell
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-11-12 13:37:38 -05:00
Paul Holzinger 52a8694705 Add anchors for flag names on docs.podman.io
Change the docs markdown so that flag names will be h4 headers.
Sphinx will automatically add anchors to headers. Add css to
make sure the flag names are not to big compared to the text.

The man pages also still renders fine but it looks a bit different.

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-11-10 15:27:08 +01:00
Daniel J Walsh c12065401f
Update podman build man page to match buildah bud man page
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-11-09 15:10:20 -05:00
TomSweeneyRedHat 7841aea292 Match build pull functionality with Docker's
This is a continuation of #8189 and #8085.

When doing a `docker build` command, if the `--pull` command is not specified
or set to `false` the pullOption used is `PullifMissing`.  This causes the
build to pull the image only if it is not present in local storage.  It also will
raise an error if the image is not found in the registry (or the registry is down),
even if the image is present in local storage.

If the `--pull` command IS specified or specified with an argument of `true`, the
build will always pull the image from the registries.  This uses the pullOption
`PullAlways`.  It also will raise an error if the image is not found in the registry,
even if the image is present in local storage.

These changes now brings the pull functionality for `podman build` into line
with `docker build`.

However, I consider this to be a breaking change.  Previously if you did
`podman build --pull`, `podman build` or `podman build --pull = true`, then
the image would be pulled from the registry if there was not an image in
local storage or if the image in the registry was newer than the one in
local storage.  An error would *NOT* be raised if there was not an image in
the registry or the registry was down as long as there was a copy in the local
storage.  An error would be raised if the image could not be retrieved from
both the registry and local storage.  This is the PullOption `PullIfNewer`.

I believe this also differs from what Buildah does at this time but I'm too
beat to chase that down at the moment.

Personally I'd like to use the `PullIfNewer` for at least `--pull` and
`--pull=true` so that you don't get an error if the registry has a network
hiccup and the image is already stored locally.  But this differs from Docker.

I'd like to post scrum about this at our next stand up to make sure we're
all on the same page about the ramifications of this change.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2020-10-31 20:11:00 -04:00
OpenShift Merge Robot 95f3ec7b08
Merge pull request #8133 from xordspar0/cpu-limit-details
[CI:DOCS] Add more details about how CPU limits work
2020-10-27 13:26:53 -04:00
Jordan Christiansen f393d32e96 Document how to enable CPU limit delegation
Signed-off-by: Jordan Christiansen <xordspar0@gmail.com>
2020-10-27 10:05:43 -05:00
Jordan Christiansen fa73b929e0 Add more details about how CPU limits work
Signed-off-by: Jordan Christiansen <xordspar0@gmail.com>
2020-10-27 09:32:41 -05:00
Daniel J Walsh 3d2ad0f97a
--tls-verify and --authfile should work for all remote commands
These options are now fully supported in the remote API and should no
longer be hidden and/or documented as non supported.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-10-19 05:55:11 -04:00
Daniel J Walsh 08cc87636e
Vendor in containers/buildah 1.16.1
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-09-11 13:37:37 -04:00
OpenShift Merge Robot 881f2dfe92
Merge pull request #7403 from QiWang19/runtime-flag
Add global options --runtime-flags
2020-09-11 11:00:11 -04:00
Daniel J Walsh 581afbb86f
Show c/storage (Buildah/CRI-O) containers in ps
The `podman ps --all` command will now show containers that
are under the control of other c/storage container systems and
the new `ps --storage` option will show only containers that are
in c/storage but are not controlled by libpod.

In the below examples, the '*working-container' entries were created
by Buildah.

```
podman ps -a
CONTAINER ID  IMAGE                             COMMAND  CREATED       STATUS                   PORTS  NAMES
9257ef8c786c  docker.io/library/busybox:latest  ls /etc  8 hours ago   Exited (0) 8 hours ago          gifted_jang
d302c81856da  docker.io/library/busybox:latest  buildah  30 hours ago  storage                         busybox-working-container
7a5a7b099d33  localhost/tom:latest              ls -alF  30 hours ago  Exited (0) 30 hours ago         hopeful_hellman
01d601fca090  localhost/tom:latest              ls -alf  30 hours ago  Exited (1) 30 hours ago         determined_panini
ee58f429ff26  localhost/tom:latest              buildah  33 hours ago  storage                         alpine-working-container

podman ps --external
CONTAINER ID  IMAGE                             COMMAND  CREATED       STATUS    PORTS  NAMES
d302c81856da  docker.io/library/busybox:latest  buildah  30 hours ago  external         busybox-working-container
ee58f429ff26  localhost/tom:latest              buildah  33 hours ago  external         alpine-working-container

```
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-09-09 06:10:02 -04:00
Qi Wang 6b0864434a Add global options --runtime-flags
Add global options --runtime-flags for setting options to container runtime.

Signed-off-by: Qi Wang <qiwan@redhat.com>
2020-09-04 15:04:36 -04:00
Daniel J Walsh 52b14a2218
Update vendor of buildah to latest code
Fix podman build man pages to match buildah functionality.

Also document .dockerignore formatted files.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-08-25 08:13:28 -04:00
Ashley Cui d419856009 Fix & add notes regarding problematic language in codebase
Podman is committed to inclusivity, a core value of open source. Historically, there have been technology terms that are problematic and divisive, and should be changed. We are currently taking time to audit our repository in order to eliminate such terminology, and replace it with more inclusive terms. We are starting where we can, with our own code, comments, and documentation. However, such terms may be used in dependencies, and must be used in our repositories at the current moment for compatibility. Podman will change these terms in our repo as soon as new and better terminology is available to us via our dependencies.

For more information: https://www.redhat.com/en/blog/making-open-source-more-inclusive-eradicating-problematic-language?sc_cid=701600000011gf0AAA

Signed-off-by: Ashley Cui <acui@redhat.com>
2020-07-15 09:13:15 -04:00
Daniel J Walsh b020d1ad13
Vendor in new version of Buildah
This also pulls in latest runc and containers/common

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-07-09 11:02:28 -04:00
Ed Santiago 281def2647 man pages: fix inconsistencies
I wrote a script to cross-reference podman --help against
man pages. It found a bunch of inconsistencies fix them:

 * options missing from man pages
 * options misspelled or misformatted in man pages (usually
   misplaced asterisks or missing dashes, but see --dns-opt)
 * one spurious comma in the actual source file --help

This is a fix in which I iterate over 'podman CMD --help'
and check for presence in man pages. The other way around
(look for flags in man pages, check podman CMD --help)
is probably impossible: there are too many special cases

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-03-10 15:03:59 -06:00
Daniel J Walsh ac354ac94a
Fix spelling mistakes in code found by codespell
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-03-07 10:30:44 -05:00
Daniel J Walsh f678b3fcf1
Update docs/source/markdown/podman-build.1.md
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-03-02 16:39:21 -05:00
Daniel J Walsh b163640c61
Allow devs to set labels in container images for default capabilities.
This patch allows users to specify the list of capabilities required
to run their container image.

Setting a image/container label "io.containers.capabilities=setuid,setgid"
tells podman that the contained image should work fine with just these two
capabilties, instead of running with the default capabilities, podman will
launch the container with just these capabilties.

If the user or image specified capabilities that are not in the default set,
the container will print an error message and will continue to run with the
default capabilities.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-03-02 16:37:32 -05:00
Stefan Becker 111af1ba4a docs: symlink to host device is resolved
Also apply changes from commit 3fd9f0c028
to the other two commands that have the --device option.

Documents #4550

Signed-off-by: Stefan Becker <chemobejk@gmail.com>
2020-02-23 14:38:34 +02:00
Stefan Becker 20cb169874 docs: add workaround for --device with rootless containers (II)
Update documentation for crun >= 0.11.

See 6df930821d

Fixes #4477

Signed-off-by: Stefan Becker <chemobejk@gmail.com>
2020-02-10 11:19:33 +02:00
Robert P. J. Day 8c825cdaae docs: replace '~' with $HOME in markdown as '~' isn't rendered properly
Apparently, a tilde is currently rendered as a single space, making
a mess of command examples that use it, so use $HOME instead.

https://github.com/mattermost/mattermost-server/issues/8228

Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
2020-01-28 12:56:55 -05:00
Stefan Becker aec62d2862 docs: add workaround for --device with rootless containers
Fixes #4477

Signed-off-by: Stefan Becker <chemobejk@gmail.com>
2019-12-17 08:34:12 +02:00
TomSweeneyRedHat 6003033ada Bump to Buildah v1.11.5
Bump to Buildah v1.11.5.  Most notably changes to the
podman build `--pull` functionality.  `--pull=true` and `--pull=false` now
work as Docker does, `--pull-never` added to supply the functionality
of the old `--pull=false`.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2019-11-13 10:57:19 -05:00
Jhon Honce 486fcd4e1e Update document formatting and packaging code
* Refactored code and Makefile to support new docs layout
* Removed some old code packaging code
* Add Readme.md to document what we're doing

Signed-off-by: Jhon Honce <jhonce@redhat.com>
Signed-off-by: baude <bbaude@redhat.com>
2019-10-31 12:31:39 -05:00
Renamed from docs/source/man/podman-build.1.md (Browse further)