---
- name: Ensure docker-related packages are installed.
  homebrew:
    name: ["docker", "docker-machine", "docker-compose"]
    state: present

- name: Ensure docker-related applications are installed.
  homebrew_cask:
    name: ["virtualbox", "kitematic"]
    state: present
  environment:
    HOMEBREW_CASK_OPTS: "--appdir={{ app_dir }} --binarydir={{ brew_dir }}/bin"

- name: Ensure `/usr/local/bin` exists.
  file:
    path: /usr/local/bin
    mode: 0755
    state: directory
  become: yes
  become_method: sudo

- name: Ensure symbolic links to files required by Kitematic exist.
  file:
    src: "{{ brew_dir }}/bin/{{ item }}"
    dest: "/usr/local/bin/{{ item }}"
    state: link
  with_items:
    - docker
    - docker-machine
  become: yes
  become_method: sudo

---
- name: Ensure docker-related packages are installed.
  homebrew:
    name: ["docker", "docker-machine", "docker-compose"]
    state: present

- name: Ensure docker-related applications are installed.
  homebrew_cask:
    name: ["virtualbox", "kitematic"]
    state: present
  environment:
    HOMEBREW_CASK_OPTS: "--appdir={{ app_dir }}"

- name: Ensure `/usr/local/bin` exists.
  file:
    path: /usr/local/bin
    mode: 0755
    state: directory
  become: yes
  become_method: sudo

- name: Ensure symbolic links to files required by Kitematic exist.
  file:
    src: "{{ brew_dir }}/bin/{{ item }}"
    dest: "/usr/local/bin/{{ item }}"
    state: link
  with_items:
    - docker
    - docker-machine
  become: yes
  become_method: sudo

Delete the removed option for Homebrew casks
Delete the removed option for Homebrew casks
