Skip to content

Commit 47e18c7

Browse files
committed
docs: document compression flags for commit and push
Signed-off-by: Jan Rodák <hony.com@seznam.cz>
1 parent e432d43 commit 47e18c7

File tree

2 files changed

+20
-3
lines changed

2 files changed

+20
-3
lines changed

docs/buildah-commit.1.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,17 @@ image, to be used at run-time for retrieving the passphrase which was used to
135135
encrypt the disk image. If not specified, a semi-random value will be derived
136136
from the base image's image ID.
137137

138+
**--compression-format** *format*
139+
140+
Specifies the compression format to use. Supported values are: `gzip`, `zstd` and `zstd:chunked`.
141+
If not specified, the format is read from the `compression_format` setting in containers.conf.
142+
Cannot be used together with **--disable-compression**.
143+
144+
**--compression-level** *level*
145+
146+
Specifies the compression level to use. The value is specific to the compression algorithm used, e.g. for zstd the accepted values are in the range 1-20 (inclusive), while for gzip it is 1-9 (inclusive).
147+
If not specified, the level is read from the `compression_level` setting in containers.conf.
148+
138149
**--disable-compression**, **-D**
139150

140151
Don't compress filesystem layers when building the image unless it is required
@@ -143,6 +154,7 @@ because image layers are compressed automatically when they are pushed to
143154
registries, and images being written to local storage would only need to be
144155
decompressed again to be stored. Compression can be forced in all cases by
145156
specifying **--disable-compression=false**.
157+
Cannot be used together with **--compression-format** or **--force-compression**.
146158

147159
**--encrypt-layer** *layer(s)*
148160

@@ -152,6 +164,11 @@ Layer(s) to encrypt: 0-indexed layer indices with support for negative indexing
152164

153165
The [protocol:keyfile] specifies the encryption protocol, which can be JWE (RFC7516), PGP (RFC4880), and PKCS7 (RFC2315) and the key material required for image encryption. For instance, jwe:/path/to/key.pem or pgp:admin@example.com or pkcs7:/path/to/x509-file.
154166

167+
**--force-compression**
168+
169+
If set, commit uses the specified compression algorithm even if the destination contains a differently-compressed variant already.
170+
Defaults to `true` if **--compression-format** is explicitly specified on the command-line or `compression_format` is set in containers.conf, `false` otherwise.
171+
155172
**--format**, **-f** *[oci | docker]*
156173

157174
Control the format for the image manifest and configuration data. Recognized

docs/buildah-push.1.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,12 @@ The default certificates directory is _/etc/containers/certs.d_.
4242

4343
Specifies the compression format to use. Supported values are: `gzip`, `zstd` and `zstd:chunked`.
4444
`zstd:chunked` is incompatible with encrypting images, and will be treated as `zstd` with a warning in that case.
45+
If not specified, the format is read from the `compression_format` setting in containers.conf.
4546

4647
**--compression-level** *level*
4748

48-
Specify the compression level used with the compression.
49-
5049
Specifies the compression level to use. The value is specific to the compression algorithm used, e.g. for zstd the accepted values are in the range 1-20 (inclusive), while for gzip it is 1-9 (inclusive).
50+
If not specified, the level is read from the `compression_level` setting in containers.conf.
5151

5252
**--creds** *creds*
5353

@@ -74,7 +74,7 @@ The [protocol:keyfile] specifies the encryption protocol, which can be JWE (RFC7
7474
**--force-compression**
7575

7676
If set, push uses the specified compression algorithm even if the destination contains a differently-compressed variant already.
77-
Defaults to `true` if `--compression-format` is explicitly specified on the command-line, `false` otherwise.
77+
Defaults to `true` if `--compression-format` is explicitly specified on the command-line or `compression_format` is set in containers.conf, `false` otherwise.
7878

7979
**--format**, **-f**
8080

0 commit comments

Comments
 (0)