31 lines
843 B
YAML
31 lines
843 B
YAML
---
|
|
- name: get ius repo install script (sponsored by rackspace)
|
|
get_url: url=https://setup.ius.io/ dest={{ home }}ius-setup force=no
|
|
|
|
- name: enable ius repo
|
|
shell: bash ius-setup removes={{ home }}ius-setup
|
|
become: yes
|
|
|
|
- name: delete ius script file after install
|
|
file: path={{ home }}ius-setup state=absent
|
|
|
|
- name: install python 3.5
|
|
yum: name={{ item }} state=latest
|
|
become: yes
|
|
with_items:
|
|
- python35u
|
|
- python35u-pip
|
|
- python-virtualenv
|
|
|
|
- name: create .virtualenv directory
|
|
file: path={{ venv }} state=directory
|
|
|
|
- name: create virtualenv
|
|
shell: pyvenv-3.5 {{ venv }}{{ project_name }} creates={{ venv }}{{ project_name }}
|
|
|
|
- name: create project directory
|
|
file: path={{ home }}{{ project_name }} state=directory
|
|
|
|
- name: install django
|
|
pip: name=django version=1.8 virtualenv={{ venv }}{{ project_name }}
|