1buildah(1)                  General Commands Manual                 buildah(1)
2
3
4

NAME

6       Buildah  -  A command line tool that facilitates building OCI container
7       images.
8
9

SYNOPSIS

11       buildah [OPTIONS] COMMAND [ARG...]
12
13

DESCRIPTION

15       The Buildah package provides a command line tool which can be used to:
16
17
18              * Create a working container, either from scratch or using an image as a starting point.
19              * Mount a working container's root filesystem for manipulation.
20              * Unmount a working container's root filesystem.
21              * Use the updated contents of a container's root filesystem as a filesystem layer to create a new image.
22              * Delete a working container or an image.
23              * Rename a local container.
24
25
26

OPTIONS

28       --log-level value
29
30
31       The log level to be used. Either "debug", "info",  "warn"  or  "error",
32       per default "error".
33
34
35       --help, -h
36
37
38       Show help
39
40
41       --registries-conf path
42
43
44       Pathname of the configuration file which specifies which container reg‐
45       istries should be consulted when completing image names  which  do  not
46       include  a registry or domain portion.  It is not recommended that this
47       option be used, as the default behavior of using the  system-wide  con‐
48       figuration (/etc/containers/registries.conf) is most often preferred.
49
50
51       --registries-conf-dir path
52
53
54       Pathname  of  the directory which contains configuration snippets which
55       specify registries which should  be  consulted  when  completing  image
56       names  which  do  not  include a registry or domain portion.  It is not
57       recommended that this option be used, as the default behavior of  using
58       the  system-wide  configuration  (/etc/containers/registries.d) is most
59       often preferred.
60
61
62       --root value
63
64
65       Storage root dir (default:  "/var/lib/containers/storage"  for  UID  0,
66       "$HOME/.local/share/containers/storage"  for  other users) Default root
67       dir is configured in /etc/containers/storage.conf
68
69
70       --runroot value
71
72
73       Storage state dir (default: "/var/run/containers/storage"  for  UID  0,
74       "/var/run/user/$UID"  for  other users) Default state dir is configured
75       in /etc/containers/storage.conf
76
77
78       --storage-driver value
79
80
81       Storage driver.  The default storage driver for UID 0 is configured  in
82       /etc/containers/storage.conf  ($HOME/.config/containers/storage.conf in
83       rootless mode), and is vfs for other users.  The  STORAGE_DRIVER  envi‐
84       ronment variable overrides the default.  The --storage-driver specified
85       driver overrides all.
86
87
88       Examples: "overlay", "devicemapper", "vfs"
89
90
91       Overriding this option will cause the storage-opt settings in /etc/con‐
92       tainers/storage.conf  to  be ignored.  The user must specify additional
93       options via the --storage-opt flag.
94
95
96       --storage-opt value
97
98
99       Storage driver option, Default storage driver options are configured in
100       /etc/containers/storage.conf  ($HOME/.config/containers/storage.conf in
101       rootless mode). The STORAGE_OPTS  environment  variable  overrides  the
102       default. The --storage-opt specified options overrides all.
103
104
105       --userns-uid-map mapping
106
107
108       Specifies  UID  mappings  which should be used to set ownership, at the
109       filesystem level, on the contents of images and containers.  Entries in
110       this  map  take  the  form of one or more triples of a starting in-con‐
111       tainer UID, a corresponding starting host-level UID, and the number  of
112       consecutive  IDs which the map entry represents.  This option overrides
113       the remap-uids setting in the options section of  /etc/containers/stor‐
114       age.conf.
115
116
117       --userns-gid-map mapping
118
119
120       Specifies  GID  mappings  which should be used to set ownership, at the
121       filesystem level, on the contents of images and containers.  Entries in
122       this  map  take  the  form of one or more triples of a starting in-con‐
123       tainer GID, a corresponding starting host-level GID, and the number  of
124       consecutive  IDs which the map entry represents.  This option overrides
125       the remap-gids setting in the options section of  /etc/containers/stor‐
126       age.conf.
127
128
129       --version, -v
130
131
132       Print the version
133
134

COMMANDS

136       ┌──────────────────────┬────────────────────────────────┐
137Command               Description                    
138       ├──────────────────────┼────────────────────────────────┤
139buildah-add(1)        │ Add  the  contents  of a file, │
140       │                      │ URL, or  a  directory  to  the │
141       │                      │ container.                     │
142       ├──────────────────────┼────────────────────────────────┤
143buildah-bud(1)        │ Build  an image using instruc‐ │
144       │                      │ tions from Dockerfiles.        │
145       ├──────────────────────┼────────────────────────────────┤
146buildah-commit(1)     │ Create an image from a working │
147       │                      │ container.                     │
148       ├──────────────────────┼────────────────────────────────┤
149buildah-config(1)     │ Update   image   configuration │
150       │                      │ settings.                      │
151       ├──────────────────────┼────────────────────────────────┤
152buildah-containers(1) │ List  the  working  containers │
153       │                      │ and their base images.         │
154       ├──────────────────────┼────────────────────────────────┤
155buildah-copy(1)       │ Copies the contents of a file, │
156       │                      │ URL, or directory into a  con‐ │
157       │                      │ tainer's working directory.    │
158       ├──────────────────────┼────────────────────────────────┤
159buildah-from(1)       │ Creates  a  new  working  con‐ │
160       │                      │ tainer, either from scratch or │
161       │                      │ using  a  specified image as a │
162       │                      │ starting point.                │
163       ├──────────────────────┼────────────────────────────────┤
164buildah-images(1)     │ List images in local storage.  │
165       ├──────────────────────┼────────────────────────────────┤
166buildah-info(1)       │ Display Buildah system  infor‐ │
167       │                      │ mation.                        │
168       ├──────────────────────┼────────────────────────────────┤
169buildah-inspect(1)    │ Inspects  the configuration of │
170       │                      │ a container or image           │
171       ├──────────────────────┼────────────────────────────────┤
172buildah-mount(1)      │ Mount the working  container's │
173       │                      │ root filesystem.               │
174       ├──────────────────────┼────────────────────────────────┤
175buildah-login(1)      │ Login to a container registry. │
176       ├──────────────────────┼────────────────────────────────┤
177buildah-logout(1)     │ Logout of a container registry │
178       ├──────────────────────┼────────────────────────────────┤
179buildah-pull(1)       │ Pull  an image from the speci‐ │
180       │                      │ fied location.                 │
181       ├──────────────────────┼────────────────────────────────┤
182buildah-push(1)       │ Push an image from local stor‐ │
183       │                      │ age to elsewhere.              │
184       ├──────────────────────┼────────────────────────────────┤
185buildah-rename(1)     │ Rename a local container.      │
186       ├──────────────────────┼────────────────────────────────┤
187buildah-rm(1)         │ Removes  one  or  more working │
188       │                      │ containers.                    │
189       ├──────────────────────┼────────────────────────────────┤
190buildah-rmi(1)        │ Removes one or more images.    │
191       ├──────────────────────┼────────────────────────────────┤
192buildah-run(1)        │ Run a command  inside  of  the │
193       │                      │ container.                     │
194       ├──────────────────────┼────────────────────────────────┤
195buildah-tag(1)        │ Add  an  additional  name to a │
196       │                      │ local image.                   │
197       ├──────────────────────┼────────────────────────────────┤
198buildah-umount(1)     │ Unmount a working  container's │
199       │                      │ root file system.              │
200       ├──────────────────────┼────────────────────────────────┤
201buildah-unshare(1)    │ Launch  a  command  in  a user │
202       │                      │ namespace  with  modified   ID │
203       │                      │ mappings.                      │
204       ├──────────────────────┼────────────────────────────────┤
205buildah-version(1)    │ Display  the  Buildah  Version │
206       │                      │ Information                    │
207       └──────────────────────┴────────────────────────────────┘
208

Files

210       storage.conf (/etc/containers/storage.conf)
211
212
213       storage.conf is the storage configuration file for all tools using con‐
214       tainers/storage
215
216
217       The storage configuration file specifies all of the available container
218       storage options for tools using shared container storage.
219
220
221       mounts.conf (/usr/share/containers/mounts.conf and optionally /etc/con‐
222       tainers/mounts.conf)
223
224
225       The  mounts.conf  files  specify volume mount files or directories that
226       are automatically mounted inside containers when executing the  buildah
227       run  or  buildah  build-using-dockerfile commands.  Container processes
228       can then use this content.  The volume mount content does not get  com‐
229       mitted to the final image.
230
231
232       Usually  these  directories are used for passing secrets or credentials
233       required by the package software to access remote package repositories.
234
235
236       For      example,      a      mounts.conf      with      the       line
237       "/usr/share/rhel/secrets:/run/secrets",       the       content      of
238       /usr/share/rhel/secrets directory is mounted on /run/secrets inside the
239       container.   This  mountpoint allows Red Hat Enterprise Linux subscrip‐
240       tions from the host to be used within the container.  It is also possi‐
241       ble  to  omit  the  destination  if it's equal to the source path.  For
242       example, specifying /var/lib/secrets will mount the directory into  the
243       same container destination path /var/lib/secrets.
244
245
246       Note  this  is not a volume mount. The content of the volumes is copied
247       into container storage, not bind mounted directly from the host.
248
249
250       registries.conf (/etc/containers/registries.conf)
251
252
253       registries.conf is the configuration file which  specifies  which  con‐
254       tainer registries should be consulted when completing image names which
255       do not include a registry or domain portion.
256
257
258       registries.d (/etc/containers/registries.d)
259
260
261       Directory which contains  configuration  snippets  which  specify  reg‐
262       istries  which should be consulted when completing image names which do
263       not include a registry or domain portion.
264
265

SEE ALSO

267       podman(1), containers-mounts.conf(5), newuidmap(1), newgidmap(1),  con‐
268       tainers-registries.conf(5), containers-storage.conf(5)
269
270

HISTORY

272       December  2017,  Originally compiled by Tom Sweeney tsweeney@redhat.com
273       ⟨mailto:tsweeney@redhat.com⟩
274
275
276
277buildah                           March 2017                        buildah(1)
Impressum