Skip to content

Commit de80514

Browse files
committed
cmd-build-with-buildah: add --parent-build for compatibility
The `--parent-build` concept doesn't translate well to the container-native path. Two main things it was used for was for maintaining valid OSTree branch history (which is no longer a concept in the OCI world) and generating good layer chunking to optimize deltas, which I think the successor to that now is coreos/rpm-ostree#5460. For easier ratcheting, allow the switch but make it do nothing.
1 parent dfbf72d commit de80514

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

src/cmd-build-with-buildah

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,14 @@ Usage: coreos-assembler build-with-buildah
1414
`cosa build` will pivot to this script when the environment variable `COREOS_ASSEMBLER_BUILD_WITH_BUILDAH` is set.
1515
1616
The following options are supported:
17-
--version=VERSION Use the given version instead of using versionary.
18-
--versionary Generate non-development version using versionary.
19-
--direct Run buildah directly rather than within supermin.
20-
--autolock=VERSION If no base lockfile used, create one from any arch build of `VERSION`.
21-
Note this is automatically enabled when adding to an existing multi-arch
22-
non-strict build.
23-
--skip-prune Skip prunning previous builds
17+
--version=VERSION Use the given version instead of using versionary.
18+
--versionary Generate non-development version using versionary.
19+
--direct Run buildah directly rather than within supermin.
20+
--autolock=VERSION If no base lockfile used, create one from any arch build of `VERSION`.
21+
Note this is automatically enabled when adding to an existing multi-arch
22+
non-strict build.
23+
--skip-prune Skip prunning previous builds
24+
--parent-build=VERSION This option does nothing and is provided for backwards compatibility.
2425
EOF
2526
}
2627

@@ -30,7 +31,7 @@ DIRECT=
3031
AUTOLOCK_VERSION=
3132
SKIP_PRUNE=
3233
rc=0
33-
options=$(getopt --options h,d --longoptions help,version:,versionary,direct,autolock:,skip-prune -- "$@") || rc=$?
34+
options=$(getopt --options h,d --longoptions help,version:,versionary,direct,autolock:,skip-prune,parent-build: -- "$@") || rc=$?
3435
[ $rc -eq 0 ] || {
3536
print_help
3637
exit 1
@@ -59,6 +60,9 @@ while true; do
5960
--skip-prune)
6061
SKIP_PRUNE=1
6162
;;
63+
--parent-build)
64+
shift
65+
;;
6266
--)
6367
shift
6468
break

0 commit comments

Comments
 (0)