Skip to content

Commit

Permalink
chore: git clone optimizations in test images
Browse files Browse the repository at this point in the history
Signed-off-by: Pratik Raj <[email protected]>
  • Loading branch information
Rajpratik71 authored Sep 9, 2020
1 parent d4c5daf commit 982b12c
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 18 deletions.
10 changes: 5 additions & 5 deletions .kokoro/docker/autosynth/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ RUN apt-get update && apt-get install -y git curl autoconf bison build-essential
RUN apt-get -y autoclean

# Install rbenv
RUN git clone https://github.com/rbenv/rbenv.git /root/.rbenv
RUN git clone --depth 1 https://github.com/rbenv/rbenv.git /root/.rbenv
RUN cd /root/.rbenv && src/configure && make -C src

ENV PATH /root/.rbenv/bin:$PATH
Expand All @@ -40,7 +40,7 @@ RUN echo 'eval "$(rbenv init -)"' >> .bashrc

# Install ruby-build
RUN mkdir -p "$(rbenv root)"/plugins
RUN git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build
RUN git clone --depth 1 https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build

# Install ruby
ENV RUBY_CONFIGURE_OPTS --disable-install-doc
Expand All @@ -49,7 +49,7 @@ RUN rbenv install 2.7.1 && rbenv global 2.7.1 \
&& gem install bundler:1.17.3 bundler:2.1.4 rake

# Install pyenv
RUN git clone https://github.com/pyenv/pyenv.git ~/.pyenv
RUN git clone --depth 1 https://github.com/pyenv/pyenv.git ~/.pyenv
RUN cd /root/.rbenv && src/configure && make -C src

ENV PATH /root/.pyenv/bin:$PATH
Expand All @@ -64,7 +64,7 @@ RUN pyenv install 3.6.9
RUN pyenv global 3.6.9

# Install nodenv
RUN git clone https://github.com/nodenv/nodenv.git ~/.nodenv
RUN git clone --depth 1 https://github.com/nodenv/nodenv.git ~/.nodenv
RUN cd /root/.nodenv && src/configure && make -C src

ENV PATH /root/.nodenv/bin:$PATH
Expand All @@ -73,7 +73,7 @@ ENV PATH /root/.nodenv/shims:$PATH
RUN echo 'export PATH="$HOME/.nodenv/bin:$PATH"' >> ~/.bashrc
RUN echo 'eval "$(nodenv init -)"' >> ~/.bashrc
RUN mkdir -p "$(nodenv root)"/plugins
RUN git clone https://github.com/nodenv/node-build.git "$(nodenv root)"/plugins/node-build
RUN git clone --depth 1 https://github.com/nodenv/node-build.git "$(nodenv root)"/plugins/node-build

# Install nodejs
RUN nodenv install 10.16.3
Expand Down
4 changes: 2 additions & 2 deletions .kokoro/docker/multi/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ RUN apt-get update && apt-get install -y git curl autoconf bison build-essential
RUN apt-get -y autoclean

# Install rbenv
RUN git clone https://github.com/rbenv/rbenv.git /root/.rbenv
RUN git clone --depth 1 https://github.com/rbenv/rbenv.git /root/.rbenv
RUN cd /root/.rbenv && src/configure && make -C src

ENV PATH /root/.rbenv/bin:$PATH
Expand All @@ -25,7 +25,7 @@ RUN echo 'eval "$(rbenv init -)"' >> .bashrc

# Install ruby-build
RUN mkdir -p "$(rbenv root)"/plugins
RUN git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build
RUN git clone --depth 1 https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build


# Install ruby
Expand Down
4 changes: 2 additions & 2 deletions .kokoro/docker/release/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ RUN apt-get -y autoclean

# Install Ruby
RUN mkdir $HOME/.ruby
RUN git clone https://github.com/rbenv/ruby-build.git $HOME/.ruby-build
RUN git clone --depth 1 https://github.com/rbenv/ruby-build.git $HOME/.ruby-build
RUN $HOME/.ruby-build/bin/ruby-build 2.7.1 $HOME/.ruby
ENV PATH /root/.ruby/bin:$PATH
ENV RUBY_CONFIGURE_OPTS --disable-install-doc
RUN echo 'gem: --no-document' >> /.gemrc
RUN gem install bundler:1.17.3 bundler:2.1.4 && gem update --system

# Install Python
RUN git clone https://github.com/pyenv/pyenv.git ~/.pyenv
RUN git clone --depth 1 https://github.com/pyenv/pyenv.git ~/.pyenv
ENV PYENV_ROOT /root/.pyenv
ENV PATH /root/.pyenv/bin:$PATH
ENV PATH /root/.pyenv/shims:$PATH
Expand Down
10 changes: 5 additions & 5 deletions .kokoro/templates/autosynth.Dockerfile.erb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ RUN apt-get update && apt-get install -y git curl autoconf bison build-essential
RUN apt-get -y autoclean

# Install rbenv
RUN git clone https://github.com/rbenv/rbenv.git /root/.rbenv
RUN git clone --depth 1 https://github.com/rbenv/rbenv.git /root/.rbenv
RUN cd /root/.rbenv && src/configure && make -C src

ENV PATH /root/.rbenv/bin:$PATH
Expand All @@ -40,7 +40,7 @@ RUN echo 'eval "$(rbenv init -)"' >> .bashrc

# Install ruby-build
RUN mkdir -p "$(rbenv root)"/plugins
RUN git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build
RUN git clone --depth 1 https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build

# Install ruby
ENV RUBY_CONFIGURE_OPTS --disable-install-doc
Expand All @@ -49,7 +49,7 @@ RUN rbenv install <%= ruby_versions[-1] %> && rbenv global <%= ruby_versions[-1]
&& gem install bundler:1.17.3 bundler:2.1.4 rake

# Install pyenv
RUN git clone https://github.com/pyenv/pyenv.git ~/.pyenv
RUN git clone --depth 1 https://github.com/pyenv/pyenv.git ~/.pyenv
RUN cd /root/.rbenv && src/configure && make -C src

ENV PATH /root/.pyenv/bin:$PATH
Expand All @@ -64,7 +64,7 @@ RUN pyenv install 3.6.9
RUN pyenv global 3.6.9

# Install nodenv
RUN git clone https://github.com/nodenv/nodenv.git ~/.nodenv
RUN git clone --depth 1 https://github.com/nodenv/nodenv.git ~/.nodenv
RUN cd /root/.nodenv && src/configure && make -C src

ENV PATH /root/.nodenv/bin:$PATH
Expand All @@ -73,7 +73,7 @@ ENV PATH /root/.nodenv/shims:$PATH
RUN echo 'export PATH="$HOME/.nodenv/bin:$PATH"' >> ~/.bashrc
RUN echo 'eval "$(nodenv init -)"' >> ~/.bashrc
RUN mkdir -p "$(nodenv root)"/plugins
RUN git clone https://github.com/nodenv/node-build.git "$(nodenv root)"/plugins/node-build
RUN git clone --depth 1 https://github.com/nodenv/node-build.git "$(nodenv root)"/plugins/node-build

# Install nodejs
RUN nodenv install 10.16.3
Expand Down
4 changes: 2 additions & 2 deletions .kokoro/templates/multi.Dockerfile.erb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ RUN apt-get update && apt-get install -y git curl autoconf bison build-essential
RUN apt-get -y autoclean

# Install rbenv
RUN git clone https://github.com/rbenv/rbenv.git /root/.rbenv
RUN git clone --depth 1 https://github.com/rbenv/rbenv.git /root/.rbenv
RUN cd /root/.rbenv && src/configure && make -C src

ENV PATH /root/.rbenv/bin:$PATH
Expand All @@ -25,7 +25,7 @@ RUN echo 'eval "$(rbenv init -)"' >> .bashrc

# Install ruby-build
RUN mkdir -p "$(rbenv root)"/plugins
RUN git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build
RUN git clone --depth 1 https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build


# Install ruby
Expand Down
4 changes: 2 additions & 2 deletions .kokoro/templates/release.Dockerfile.erb
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ RUN apt-get -y autoclean

# Install Ruby
RUN mkdir $HOME/.ruby
RUN git clone https://github.com/rbenv/ruby-build.git $HOME/.ruby-build
RUN git clone --depth 1 https://github.com/rbenv/ruby-build.git $HOME/.ruby-build
RUN $HOME/.ruby-build/bin/ruby-build <%= ruby_versions[-1] %> $HOME/.ruby
ENV PATH /root/.ruby/bin:$PATH
ENV RUBY_CONFIGURE_OPTS --disable-install-doc
RUN echo 'gem: --no-document' >> /.gemrc
RUN gem install bundler:1.17.3 bundler:2.1.4 && gem update --system

# Install Python
RUN git clone https://github.com/pyenv/pyenv.git ~/.pyenv
RUN git clone --depth 1 https://github.com/pyenv/pyenv.git ~/.pyenv
ENV PYENV_ROOT /root/.pyenv
ENV PATH /root/.pyenv/bin:$PATH
ENV PATH /root/.pyenv/shims:$PATH
Expand Down

0 comments on commit 982b12c

Please sign in to comment.