Skip to content

Commit

Permalink
Move website build to CircleCI (#535)
Browse files Browse the repository at this point in the history
* add circleci website build

* remove packer.json since CircleCI builds the site
  • Loading branch information
alvin-huang authored Nov 20, 2018
1 parent 75714e0 commit 4a3a10c
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 34 deletions.
43 changes: 43 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
version: 2
jobs:
build-website:
# setting the working_directory along with the checkout path allows us to not have
# to cd into the website/ directory for commands
working_directory: ~/project/website
docker:
- image: hashicorp/middleman-hashicorp:0.3.35
steps:
- checkout:
path: ~/project

# restores gem cache
- restore_cache:
key: static-site-gems-v1-{{ checksum "Gemfile.lock" }}

- run:
name: install gems
command: bundle check || bundle install --path vendor/bundle --retry=3

# saves gem cache if we have changed the Gemfile
- save_cache:
key: static-site-gems-v1-{{ checksum "Gemfile.lock" }}
paths:
- ~/project/website/vendor/bundle

- run:
name: middleman build
command: bundle exec middleman build

- run:
name: website deploy
command: ./scripts/deploy.sh

workflows:
version: 2
website:
jobs:
- build-website:
context: static-sites
filters:
branches:
only: stable-website
34 changes: 0 additions & 34 deletions website/packer.json

This file was deleted.

0 comments on commit 4a3a10c

Please sign in to comment.