From 24264ef0dc85df3e5b6cb438fbf5e267a75ca95e Mon Sep 17 00:00:00 2001 From: Seth Vargo Date: Wed, 8 Mar 2017 11:22:54 -0800 Subject: [PATCH] Update middleman-hashicorp --- website/Gemfile | 5 +--- website/Gemfile.lock | 62 +++++++++++++++++++++----------------------- website/Makefile | 32 +++++++++-------------- website/README.md | 34 ++++++++---------------- website/Vagrantfile | 27 ------------------- website/packer.json | 18 +++++-------- 6 files changed, 59 insertions(+), 119 deletions(-) delete mode 100644 website/Vagrantfile diff --git a/website/Gemfile b/website/Gemfile index 76e7fafef..f9b604b3c 100644 --- a/website/Gemfile +++ b/website/Gemfile @@ -1,6 +1,3 @@ source "https://rubygems.org" -gem "middleman-hashicorp", - git: "https://github.com/hashicorp/middleman-hashicorp.git" - -gem "htmlbeautifier" +gem "middleman-hashicorp", "0.3.12" diff --git a/website/Gemfile.lock b/website/Gemfile.lock index b5fe9cc0f..ff3b5b7b0 100644 --- a/website/Gemfile.lock +++ b/website/Gemfile.lock @@ -1,30 +1,17 @@ -GIT - remote: https://github.com/hashicorp/middleman-hashicorp.git - revision: 462267352881543bbc5d2606f1ca17a6165ac8ec - specs: - middleman-hashicorp (0.3.5) - bootstrap-sass (~> 3.3) - builder (~> 3.2) - middleman (~> 3.4) - middleman-livereload (~> 3.4) - middleman-syntax (~> 3.0) - redcarpet (~> 3.3) - GEM remote: https://rubygems.org/ specs: - activesupport (4.2.7.1) + activesupport (4.2.8) i18n (~> 0.7) - json (~> 1.7, >= 1.7.7) minitest (~> 5.1) thread_safe (~> 0.3, >= 0.3.4) tzinfo (~> 1.1) - autoprefixer-rails (6.5.3) + autoprefixer-rails (6.7.6) execjs bootstrap-sass (3.3.7) autoprefixer-rails (>= 5.2.1) sass (>= 3.3.4) - builder (3.2.2) + builder (3.2.3) capybara (2.4.4) mime-types (>= 1.16) nokogiri (>= 1.3.3) @@ -35,7 +22,7 @@ GEM coffee-script (2.4.1) coffee-script-source execjs - coffee-script-source (1.10.0) + coffee-script-source (1.12.2) compass (1.0.3) chunky_png (~> 1.2) compass-core (~> 1.0.2) @@ -52,19 +39,18 @@ GEM eventmachine (>= 0.12.9) http_parser.rb (~> 0.6.0) erubis (2.7.0) - eventmachine (1.2.0.1) + eventmachine (1.2.3) execjs (2.7.0) - ffi (1.9.14) + ffi (1.9.18) haml (4.0.7) tilt hike (1.2.3) hooks (0.4.1) uber (~> 0.0.14) - htmlbeautifier (1.2.0) http_parser.rb (0.6.0) i18n (0.7.0) - json (1.8.3) - kramdown (1.12.0) + json (2.0.3) + kramdown (1.13.2) listen (3.0.8) rb-fsevent (~> 0.9, >= 0.9.4) rb-inotify (~> 0.9, >= 0.9.7) @@ -91,6 +77,14 @@ GEM rack (>= 1.4.5, < 2.0) thor (>= 0.15.2, < 2.0) tilt (~> 1.4.1, < 2.0) + middleman-hashicorp (0.3.12) + bootstrap-sass (~> 3.3) + builder (~> 3.2) + middleman (~> 3.4) + middleman-livereload (~> 3.4) + middleman-syntax (~> 3.0) + redcarpet (~> 3.3) + turbolinks (~> 5.0) middleman-livereload (3.4.6) em-websocket (~> 0.5.1) middleman-core (>= 3.3) @@ -107,9 +101,9 @@ GEM mime-types-data (~> 3.2015) mime-types-data (3.2016.0521) mini_portile2 (2.1.0) - minitest (5.9.1) + minitest (5.10.1) multi_json (1.12.1) - nokogiri (1.6.8.1) + nokogiri (1.7.0.1) mini_portile2 (~> 2.1.0) padrino-helpers (0.12.8.1) i18n (~> 0.6, >= 0.6.7) @@ -123,11 +117,11 @@ GEM rack-test (0.6.3) rack (>= 1.0) rb-fsevent (0.9.8) - rb-inotify (0.9.7) + rb-inotify (0.9.8) ffi (>= 0.5.0) - redcarpet (3.3.4) - rouge (2.0.6) - sass (3.4.22) + redcarpet (3.4.0) + rouge (2.0.7) + sass (3.4.23) sprockets (2.12.4) hike (~> 1.2) multi_json (~> 1.0) @@ -138,9 +132,12 @@ GEM sprockets-sass (1.3.1) sprockets (~> 2.0) tilt (~> 1.1) - thor (0.19.1) - thread_safe (0.3.5) + thor (0.19.4) + thread_safe (0.3.6) tilt (1.4.1) + turbolinks (5.0.1) + turbolinks-source (~> 5) + turbolinks-source (5.0.0) tzinfo (1.2.2) thread_safe (~> 0.1) uber (0.0.15) @@ -154,8 +151,7 @@ PLATFORMS ruby DEPENDENCIES - htmlbeautifier - middleman-hashicorp! + middleman-hashicorp (= 0.3.12) BUNDLED WITH - 1.13.6 + 1.14.6 diff --git a/website/Makefile b/website/Makefile index bdb362513..91a898c3a 100644 --- a/website/Makefile +++ b/website/Makefile @@ -1,22 +1,14 @@ -all: build +VERSION?="0.3.12" -init: - bundle +website: + @echo "==> Starting website in Docker..." + @docker run \ + --interactive \ + --rm \ + --tty \ + --publish "4567:4567" \ + --publish "35729:35729" \ + --volume "$(shell pwd):/website" \ + hashicorp/middleman-hashicorp:${VERSION} -docker-dev: - docker run -it --expose 4567 -p 4567:4567 -v "$(PWD)":/usr/src/app -w /usr/src/app ruby:2.3.1 \ - bash -c "apt-get update && apt-get -qy install curl git libgmp3-dev nodejs && \ - gem install bundler && bundle install && make dev" - -dev: init - PACKER_DISABLE_DOWNLOAD_FETCH=true PACKER_VERSION=1.0 bundle exec middleman server - -build: init - PACKER_DISABLE_DOWNLOAD_FETCH=true PACKER_VERSION=1.0 bundle exec middleman build - -format: - bundle exec htmlbeautifier -t 2 source/*.erb - bundle exec htmlbeautifier -t 2 source/layouts/*.erb - @pandoc -v > /dev/null || echo "pandoc must be installed in order to format markdown content" - pandoc -v > /dev/null && find . -iname "*.html.md" | xargs -I{} bash -c "pandoc -r markdown -w markdown --tab-stop=4 --atx-headers -s --columns=80 {} > {}.new"\; || true - pandoc -v > /dev/null && find . -iname "*.html.md" | xargs -I{} bash -c "mv {}.new {}"\; || true +.PHONY: website diff --git a/website/README.md b/website/README.md index e86ccc60e..64085fffc 100644 --- a/website/README.md +++ b/website/README.md @@ -1,33 +1,21 @@ -# Packer Website +# Vault Website -This subdirectory contains the entire source for the [Packer website](http://www.packer.io). -This is a [Middleman](http://middlemanapp.com) project, which builds a static -site from these source files. +This subdirectory contains the entire source for the [Packer Website][packer]. +This is a [Middleman][middleman] project, which builds a static site from these +source files. ## Contributions Welcome! If you find a typo or you feel like you can improve the HTML, CSS, or -JavaScript, we welcome contributions. Feel free to open issues or pull -requests like any normal GitHub project, and we'll merge it in. +JavaScript, we welcome contributions. Feel free to open issues or pull requests +like any normal GitHub project, and we'll merge it in. ## Running the Site Locally -Running the site locally is simple. Clone this repo and run the following -commands: +Running the site locally is simple. Clone this repo and run `make website`. -``` -make dev -``` +Then open up `http://localhost:4567`. Note that some URLs you may need to append +".html" to make them work (in the navigation). -Then open up `localhost:4567`. Note that some URLs you may need to append -".html" to make them work (in the navigation and such). - -## Keeping Tidy - -To keep the source code nicely formatted, there is a `make format` target. This -runs `htmlbeautify` and `pandoc` to reformat the source code so it's nicely formatted. - - make format - -Note that you will need to install pandoc yourself. `make format` will skip it -if you don't have it installed. \ No newline at end of file +[middleman]: https://www.middlemanapp.com +[vault]: https://www.packer.io diff --git a/website/Vagrantfile b/website/Vagrantfile deleted file mode 100644 index bd044c27f..000000000 --- a/website/Vagrantfile +++ /dev/null @@ -1,27 +0,0 @@ -# -*- mode: ruby -*- -# vi: set ft=ruby : - -$script = <