Description
I was trying to install ANTS through sources and it was giving me the following error:
"The unauthenticated git protocol on port 9418 is no longer supported"
I found out that git requires a change in the default url and this is easily done with a git config command.
This is the code that works for me for installing ANTS with source:
ENV ANTSPATH="/opt/ants-latest/bin"
PATH="/opt/ants-latest/bin:$PATH"
LD_LIBRARY_PATH="/opt/ants-latest/lib:$LD_LIBRARY_PATH"
RUN apt-get update -qq
&& apt-get install -y -q --no-install-recommends
cmake
g++
gcc
git
make
zlib1g-dev
&& apt-get clean
&& rm -rf /var/lib/apt/lists/*
&& mkdir -p /tmp/ants/build
&& git config --global url."https://".insteadOf git://
&& git clone https://github.com/ANTsX/ANTs.git /tmp/ants/source
&& cd /tmp/ants/build
&& cmake -DBUILD_SHARED_LIBS=ON -DBUILD_TESTING=OFF /tmp/ants/source
&& make -j1
&& mkdir -p /opt/ants-latest
&& mv bin lib /opt/ants-latest/
&& mv /tmp/ants/source/Scripts/* /opt/ants-latest/bin
&& rm -rf /tmp/ants
Hope this helps!