-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #112 from screwdriver-cd/dockerize
feat: create a Dockerfile that serves an instance of the guide
- Loading branch information
Showing
2 changed files
with
32 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
FROM ruby:2.4-alpine | ||
|
||
# Create our application directory | ||
RUN mkdir -p /usr/src/app | ||
WORKDIR /usr/src/app | ||
|
||
# Install guide | ||
RUN set -x \ | ||
# Missing https for some magical reason; need build tools for jekyll install | ||
&& apk add --no-cache --update ca-certificates build-base \ | ||
# You know you're using a lean image when you need to install wget | ||
&& apk add --virtual wget \ | ||
# Fetch the latest Guide release | ||
&& wget -q -O - https://github.com/screwdriver-cd/guide/releases/latest \ | ||
| egrep -o '/screwdriver-cd/guide/releases/download/v[0-9.]*/guide.tgz' \ | ||
| wget --base=http://github.com/ -i - -O guide.tgz \ | ||
&& tar -zxvf guide.tgz \ | ||
# General clean-up | ||
&& rm -rf guide.tgz \ | ||
# Need jekyll to serve the pages | ||
&& gem install jekyll | ||
|
||
EXPOSE 4000 | ||
|
||
CMD ["jekyll", "serve", "--force_polling", "-H", "0.0.0.0", "-P", "4000"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters