Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axilleas@axilleas.me>2017-09-08 18:04:03 +0300
committerAchilleas Pipinellis <axil@gitlab.com>2018-02-15 15:00:19 +0300
commitf8501806242e4425b531e97e67f842ebb351a8f6 (patch)
treee18f4f7062a8f024478ed6d06d76a0458853895d /dockerfiles/Dockerfile.bootstrap
parent785008677aaa61a1db50540d800dd4fd306f6877 (diff)
Add Dockerfiles that will help build a versioned website
Diffstat (limited to 'dockerfiles/Dockerfile.bootstrap')
-rw-r--r--dockerfiles/Dockerfile.bootstrap35
1 files changed, 35 insertions, 0 deletions
diff --git a/dockerfiles/Dockerfile.bootstrap b/dockerfiles/Dockerfile.bootstrap
new file mode 100644
index 00000000..ae776e46
--- /dev/null
+++ b/dockerfiles/Dockerfile.bootstrap
@@ -0,0 +1,35 @@
+#
+# This is the Nanoc boostrap Dockerfile which builds an image that contains
+# all Nanoc's runtime dependencies and gems.
+#
+
+FROM ruby:2.5-alpine
+
+# Install packages needed at build and run time
+RUN apk add --no-cache --virtual build-deps \
+ build-base \
+ ruby-dev \
+ libxslt-dev
+
+# Do not install rdoc to save some space
+RUN echo 'gem: --no-document' >> /etc/gemrc
+
+# Copy scripts used for static HTML post-processing
+COPY scripts /scripts/
+
+# Copy only Gemfile and Gemfile.lock
+COPY /Gemfile* /source/
+WORKDIR /source
+
+# Install gems
+RUN NOKOGIRI_USE_SYSTEM_LIBRARIES=1 bundle install --jobs 4
+
+# Cleanup
+RUN apk del build-deps \
+ && rm -rf /usr/lib/ruby/gems/*/cache/*.gem \
+ && rm -rf /usr/src/Gemfile*
+
+# Install packages needed at build and run time
+RUN apk add --no-cache libxslt libcurl openssl git grep bash
+
+CMD echo "Nothing to do here. This is the bootstrap image that contains all dependencies to build the docs site."