mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 01:58:41 -05:00
Update Dockerfile_local to rebuild faster
This makes it so that cached layers can be used when all that is changing is VMPooler's code, and not its gems.
This commit is contained in:
parent
b9a5b52cdd
commit
6db71d8589
1 changed files with 11 additions and 5 deletions
|
|
@ -10,9 +10,6 @@
|
||||||
|
|
||||||
FROM jruby:9.2-jdk
|
FROM jruby:9.2-jdk
|
||||||
|
|
||||||
COPY docker/docker-entrypoint.sh /usr/local/bin/
|
|
||||||
COPY ./ ./
|
|
||||||
|
|
||||||
ENV RACK_ENV=production
|
ENV RACK_ENV=production
|
||||||
|
|
||||||
RUN apt-get update -qq && \
|
RUN apt-get update -qq && \
|
||||||
|
|
@ -21,9 +18,18 @@ RUN apt-get update -qq && \
|
||||||
apt-get autoremove -y && \
|
apt-get autoremove -y && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
COPY docker/docker-entrypoint.sh /usr/local/bin/
|
||||||
|
COPY ./Gemfile ./
|
||||||
|
COPY ./vmpooler.gemspec ./
|
||||||
|
COPY ./lib/vmpooler/version.rb ./lib/vmpooler/version.rb
|
||||||
|
|
||||||
RUN gem install bundler && \
|
RUN gem install bundler && \
|
||||||
bundle install && \
|
bundle config set --local jobs 3 && \
|
||||||
gem build vmpooler.gemspec && \
|
bundle install
|
||||||
|
|
||||||
|
COPY ./ ./
|
||||||
|
|
||||||
|
RUN gem build vmpooler.gemspec && \
|
||||||
gem install vmpooler*.gem && \
|
gem install vmpooler*.gem && \
|
||||||
chmod +x /usr/local/bin/docker-entrypoint.sh
|
chmod +x /usr/local/bin/docker-entrypoint.sh
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue