Skip to content
Snippets Groups Projects
Commit 32d48e6f authored by Zhou Zheng Sheng's avatar Zhou Zheng Sheng
Browse files

Speedup Git Cloning Ansible Repository

When building kolla-ansible image, it clones ansible source code from
github. Since we just need the source code but not the commit history,
there is no need to download all the commit log objects. This patch adds
"--depth 1" option to git clone command. This will speedup kolla-ansible
image building a lot, especially in countries with slow Internet access.

Change-Id: I834f83a127350415a5861a2f5b2982df3d3e3f5a
Closes-Bug: #1488744
parent 93d709e6
No related branches found
No related tags found
No related merge requests found
......@@ -16,7 +16,7 @@ RUN yum -y install \
RUN pip install -U pip wheel \
&& pip install python-openstackclient shade
RUN git clone https://github.com/ansible/ansible.git \
RUN git clone --depth 1 https://github.com/ansible/ansible.git \
&& cd ansible \
&& git submodule update --init --recursive \
&& pip install .
......
......@@ -25,7 +25,7 @@ RUN apt-get install -y --no-install-recommends git
RUN pip install shade
RUN git clone https://github.com/ansible/ansible.git \
RUN git clone --depth 1 https://github.com/ansible/ansible.git \
&& cd ansible \
&& git submodule update --init --recursive \
&& pip install --install-option="--install-scripts=/usr/bin" .
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment