mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-04 18:00:08 +00:00
Prevent SIGPIPE errors causing the version check line to fail
The use of pipe when process the version command can lead to 141 failues on some systems. Using a prefix of tail can prevent this.
This commit is contained in:
parent
6e4bc5427c
commit
ec33164686
@ -32,7 +32,7 @@ kube::etcd::start() {
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
version=$(etcd --version | head -n 1 | cut -d " " -f 3)
|
version=$(etcd --version | tail -n +1 | head -n 1 | cut -d " " -f 3)
|
||||||
if [[ "${version}" < "${ETCD_VERSION}" ]]; then
|
if [[ "${version}" < "${ETCD_VERSION}" ]]; then
|
||||||
kube::log::usage "etcd version ${ETCD_VERSION} or greater required."
|
kube::log::usage "etcd version ${ETCD_VERSION} or greater required."
|
||||||
kube::log::info "You can use 'hack/install-etcd.sh' to install a copy in third_party/."
|
kube::log::info "You can use 'hack/install-etcd.sh' to install a copy in third_party/."
|
||||||
|
Loading…
Reference in New Issue
Block a user