diff --git a/Dockerfile b/Dockerfile index 1aa7e5203..613d4786f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -39,7 +39,7 @@ RUN equivs-build python3-fake-debian-package RUN set -x && \ git clone https://github.com/intel/ipmctl.git && \ cd ipmctl && \ - tag=$(curl --silent https://github.com/intel/ipmctl/releases/latest | sed -e 's;.*tag/\([^"]*\).*;\1;') && \ + tag=$(basename $(curl -Ls -o /dev/null -w %{url_effective} https://github.com/intel/ipmctl/releases/latest)) && \ git checkout $tag && \ mkdir build && \ cd build && \ diff --git a/Dockerfile.UBI b/Dockerfile.UBI index fe5a51e36..394bbe58f 100644 --- a/Dockerfile.UBI +++ b/Dockerfile.UBI @@ -59,7 +59,7 @@ RUN set -x && \ mkdir -p /usr/local/share/package-licenses && \ cp LICENSE /usr/local/share/package-licenses/ipmctl.LICENSE && \ cd ipmctl && \ - tag=$(curl --silent https://github.com/intel/ipmctl/releases/latest | sed -e 's;.*tag/\([^"]*\).*;\1;') && \ + tag=$(basename $(curl -Ls -o /dev/null -w %{url_effective} https://github.com/intel/ipmctl/releases/latest)) && \ git checkout $tag && \ mkdir build && \ cd build && \