Created
January 26, 2020 09:17
-
-
Save ThabetAmer/b238ac9b060b5fb4872a1fab41068db5 to your computer and use it in GitHub Desktop.
Jekyll serve via Docker
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
# installs gems then serves web on http://0.0.0.0:4000 | |
# | |
## you may want to exclude vendor/bundle in _config.xml | |
# | |
## For Github pages, refer to https://pages.github.com/versions/ to find supported Jekyll version | |
## as in your Gemfile. | |
# | |
export JEKYLL_VERSION=3.8.5 | |
docker run --rm -it \ | |
-v "$(pwd):/srv/jekyll" \ | |
-v "$(pwd)/vendor/bundle:/usr/local/bundle" \ | |
-p4000:4000 \ | |
jekyll/jekyll:$JEKYLL_VERSION \ | |
bundle install && bundle exec jekyll serve --host 0.0.0.0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment