about summary refs log tree commit diff
path: root/Dockerfile
diff options
context:
space:
mode:
authorRyan Wade <ryan.wade@protonmail.com>2017-04-06 15:41:00 +0800
committerRyan Wade <ryan.wade@protonmail.com>2017-04-06 15:42:16 +0800
commita2637c17200f9dd2eea9e130368cea87076823c7 (patch)
tree7a3d7159dc74063a2e7a25bd9f61466281ea798c /Dockerfile
parent51d7caaf1994ee3cb531b64841e12d129dded298 (diff)
Optimize Dockerfile
Optimize Dockerfile, reduce build time.
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile4
1 files changed, 3 insertions, 1 deletions
diff --git a/Dockerfile b/Dockerfile
index bcc911343..f5eb08893 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -5,7 +5,7 @@ ENV RAILS_ENV=production \
 
 WORKDIR /mastodon
 
-COPY . /mastodon
+COPY Gemfile Gemfile.lock package.json yarn.lock /mastodon/
 
 RUN BUILD_DEPS=" \
     postgresql-dev \
@@ -28,4 +28,6 @@ RUN BUILD_DEPS=" \
  && apk del $BUILD_DEPS \
  && rm -rf /tmp/* /var/cache/apk/*
 
+COPY . /mastodon
+
 VOLUME /mastodon/public/system /mastodon/public/assets