Skip to content

Commit d707d8a

Browse files
mangardaattali
authored andcommitted
Add Docker (daattali#114)
* added docker * link to docker install
1 parent 0cb0f5e commit d707d8a

2 files changed

Lines changed: 56 additions & 10 deletions

File tree

Dockerfile

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
FROM mangar/jekyll:1.0
2+
3+
MAINTAINER Marcio Mangar "marcio.mangar@gmail.com"
4+
5+
RUN gem install jekyll -v 3.1.6
6+
RUN gem install bundler
7+
8+
RUN gem install execjs
9+
RUN gem install therubyracer
10+
RUN gem install github-pages
11+
RUN gem install jekyll-paginate
12+
RUN gem install jekyll-seo-tag
13+
RUN gem install jekyll-gist
14+
RUN gem install json -v 1.8.3
15+
16+
RUN gem install minitest -v 5.9.0
17+
RUN gem install colorator -v 0.1
18+
RUN gem install ffi -v 1.9.10
19+
RUN gem install kramdown -v 1.10.0
20+
RUN gem install rouge -v 1.10.1
21+
RUN gem install pkg-config -v 1.1.7
22+
RUN gem install terminal-table -v 1.6.0
23+
RUN gem install ethon -v 0.9.0
24+
RUN gem install nokogiri -v 1.6.8
25+
RUN gem install activesupport -v 4.2.6
26+
RUN gem install html-pipeline -v 2.4.1
27+
RUN gem install jekyll-watch -v 1.4.0
28+
RUN gem install github-pages-health-check -v 1.1.0
29+
RUN gem install jekyll-github-metadata -v 2.0.0
30+
RUN gem install jekyll-mentions -v 1.1.2
31+
RUN gem install jekyll-redirect-from -v 0.10.0
32+
RUN gem install jemoji -v 0.6.2
33+
RUN gem install github-pages -v 82
34+
35+
36+
37+
RUN mkdir -p /app
38+
ADD ./ /app
39+
40+
WORKDIR /app
41+
42+
EXPOSE 4000
43+
44+
CMD bundle exec jekyll serve

README.md

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Scroll down to see the steps involved, but here is a 40-second video just as a r
3434

3535
![Installation steps](img/install-steps.gif)
3636

37-
### 1. Fork this repository
37+
### 1. Fork this repository
3838

3939
(Assuming you are on this page and logged into GitHub) Fork this repository by clicking the *Fork* button on the top right corner. Forking means that you now copied this whole project and all the files into your account.
4040

@@ -153,7 +153,7 @@ To set up a GitHub Project page, simply fork this repository into a branch calle
153153

154154
### Advanced features (including how to use a custom URL address for your site)
155155

156-
I wrote [a blog post](http://deanattali.com/2015/03/12/beautiful-jekyll-how-to-build-a-site-in-minutes/) describing some more advanced features that I used in my website that are applicable to any Jekyll site. It describes how I used a custom URL for my site (deanattali.com instead of daattali.github.io), how to add a Google-powered search into your site, and provides a few more details about having an RSS feed.
156+
I wrote [a blog post](http://deanattali.com/2015/03/12/beautiful-jekyll-how-to-build-a-site-in-minutes/) describing some more advanced features that I used in my website that are applicable to any Jekyll site. It describes how I used a custom URL for my site (deanattali.com instead of daattali.github.io), how to add a Google-powered search into your site, and provides a few more details about having an RSS feed.
157157

158158
### Featured users (success stories!)
159159

@@ -190,19 +190,21 @@ Want your website featured here? [Contact me](http://deanattali.com/aboutme#cont
190190
| [epwalsh.com](https://epwalsh.com) | Evan Pete Walsh | PhD candidate (Statistics and Mathematics) at Iowa State University |
191191
| [otomatikmuhendis.com](http://otomatikmuhendis.com/) | Olcay Bayram | Software engineer |
192192

193-
### Very advanced: Local development
194193

195-
Beautiful Jekyll is meant to be so simple to use that you can do it all within the browser. However, if you'd like to develop locally on your own machine, that's possible too if you're comfortable with command line. Follow these simple steps to do that with Vagrant:
194+
### Docker
196195

197-
1. Install [VirtualBox](http://virtualbox.org) and [Vagrant](https://www.vagrantup.com)
196+
Beautiful Jekyll is meant to be so simple to use that you can do it all within the browser. However, if you'd like to develop locally on your own machine, that's possible too if you're comfortable with command line. Follow these simple steps to do that with Docker:
197+
198+
1. Make sure that you have Docker installed on your local environment. More details can be found [here](https://docs.docker.com/engine/installation/)
198199
2. Clone your fork `git clone git@github.com:yourusername/yourusername.github.io.git`
199-
3. Inside your repository folder, run `vagrant up`
200-
4. View your website at `http://0.0.0.0:4000` on *nix or `http://127.0.0.1:4000` on Windows.
201-
5. Commit any changes and push everything to the master branch of your GitHub repository. GitHub Pages will then rebuild and serve your website automatically.
200+
3. Inside your repository folder, run:
201+
```
202+
docker run -p 4000:4000 -v `pwd`:/app mangar/jekyll:1.1 bash -c "bundle install; bundle exec jekyll serve"
203+
```
204+
4. View your website at <http://localhost:4000>.
205+
202206

203-
Disclaimer: I personally am NOT using local development so I don't know much about running Jekyll locally. If you follow this route, please don't ask me questions because unfortunately I honestly won't be able to help!
204207

205-
Additionally, if you choose to deploy Jekyll using a local ruby installation, you can tell Jekyll to automatically categorize your blog posts by tags. You just need to set `link-tags: true` in `_config.yml`. Jekyll will then generate a new page for each unique tag which lists all of the posts that belong to that tag.
206208

207209
### Credits
208210

0 commit comments

Comments
 (0)