-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathprovision-vagrant-vm.yml
41 lines (29 loc) · 1.04 KB
/
provision-vagrant-vm.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
---
- name: Provision Vagrant VM
hosts: all
become: True
gather_facts: False
tasks:
- name: Create dir for storing apt cache in /vagrant
file: state=directory path=/vagrant/apt/cache/partial
- name: Set apt cache location
copy: content='dir::cache::archives "/vagrant/apt/cache";' dest=/etc/apt/apt.conf.d/cache
- debug: msg="Running 'apt dist-upgrade', this may take a while..."
# May take a while...
- name: Apt dist-upgrade
apt: update_cache=yes upgrade=dist cache_valid_time=3600
- name: Install vim, git, ansible, python-keyczar, expect, python3-virtualenv
apt:
name:
- vim
# for running tests
- git
- expect
# Old Ansible (2.0.0.2) on system python (2.7.12)
- ansible
- python-keyczar
# Python3 environment
- python3-venv # to create venv
- python3-pip # pip for python3
- name: Create directory for python3 venv
file: state=directory path=/opt/py3