Docker has adopted GNU-style long options with v0.8.0 :) [1]:
First step toward getopt style flags:
As we keep compatibility with flags like -dns we can't have -i -t ->
-it but at least - and -- are now correct.
Strangely, I the short form doesn't always work for me anymore:
$ docker run -name my-container -hostname my-container wking/gentoo /bin/bash
flag provided but not defined: -hostname
Note that the -name works fine but the newer --hostname requires the
'--' form.
[1]: https://github.com/dotcloud/docker/pull/3322
e71dbf4 (update commands.go, 2013-12-23)
msg "extract Busybox binary to ${SUBDIR}"
THIS_DIR=$(dirname $($REALPATH $0))
CONTAINER="${NAMESPACE}-gentoo-${DATE}-extract-busybox"
- "${DOCKER}" run -name "${CONTAINER}" -v "${THIS_DIR}/${SUBDIR}/":/tmp "${NAMESPACE}/gentoo:${DATE}" cp /bin/busybox /tmp/
+ "${DOCKER}" run --name "${CONTAINER}" -v "${THIS_DIR}/${SUBDIR}/":/tmp "${NAMESPACE}/gentoo:${DATE}" cp /bin/busybox /tmp/
"${DOCKER}" rm "${CONTAINER}"
}