- hosts: localhost become: yes become_user: root become_method: sudo gather_facts: yes vars_files: - vars/main.yml pre_tasks: - name: Update Apt Cache apt: update_cache=yes cache_valid_time=86400 when: ansible_os_family == "Debian" - name: Ubuntu Packages apt: > pkg={{item}} state=installed with_items: - htop - iotop - git - sysstat - vim - tmux - tree - tcpdump - unzip when: ansible_os_family == "Debian" roles: - { role: rvm_io.ruby, tags: ruby, become: yes, rvm1_rubies: ['ruby-2.3.3'], rvm1_install_flags: '--user-install', rvm1_install_path: /home/vagrant/.rvm, rvm1_user: vagrant }