---
- name: Install python-apt for apt_repository.
  apt: name={{ item }} state=latest
  with_items:
  - python-apt
  - python-pycurl
  sudo: yes

- name: Add the Brightbox PPA
  apt_repository: repo=ppa:brightbox/ruby-ng state=present
  sudo: yes

- name: Install system packages necessary for Jekyll
  apt: name={{ item }} state=latest update_cache=yes
  with_items:
  - build-essential
  - ruby2.1-dev
  - nodejs
  sudo: yes

- name: Install Jekyll and necessary gems
  gem: name={{ item }} state=latest executable=/usr/bin/gem2.1 user_install=no
  with_items:
  - jekyll
  - jekyll-less
  - therubyracer
  - execjs
  - stringex
  sudo: yes

---
- name: Install python-apt for apt_repository.
  apt: name={{ item }} state=latest
  with_items:
  - python-apt
  - python-pycurl
  sudo: yes

- name: Add the Brightbox PPA
  apt_repository: repo=ppa:brightbox/ruby-ng state=present
  sudo: yes

- name: Install system packages necessary for Jekyll
  apt: name={{ item }} state=latest update_cache=yes
  with_items:
  - build-essential
  - ruby2.1-dev
  - nodejs
  sudo: yes

- name: Install bundler
  gem: name=bundler state=latest
  sudo: yes

- name: Install Jekyll and its dependencies
  command: bundle install --gemfile=/vagrant_data/Gemfile
  sudo: yes

Install Bundler, then use the Gemfile(.lock).
Install Bundler, then use the Gemfile(.lock).
