aboutsummaryrefslogtreecommitdiff
path: root/ansible/roles/install-app
diff options
context:
space:
mode:
authorMilo Casagrande <milo.casagrande@linaro.org>2014-05-28 15:13:18 +0200
committerMilo Casagrande <milo.casagrande@linaro.org>2014-05-28 15:13:18 +0200
commit180ed012d384e1a5ca5f006593f3024b22accc10 (patch)
treeed098f7da490e39540fe23ebd893ae70de8b9d0e /ansible/roles/install-app
parentd98aef32d6cc2d7b32f2f44cbe5982023cc291cb (diff)
ansible: Fix ansible playbooks.
* Make things run under virtualenv. Change-Id: I04d73045791e6da8cedc1a5105f28caa990c3b6d
Diffstat (limited to 'ansible/roles/install-app')
-rw-r--r--ansible/roles/install-app/tasks/main.yml21
1 files changed, 17 insertions, 4 deletions
diff --git a/ansible/roles/install-app/tasks/main.yml b/ansible/roles/install-app/tasks/main.yml
index a5827ba..ba3d8db 100644
--- a/ansible/roles/install-app/tasks/main.yml
+++ b/ansible/roles/install-app/tasks/main.yml
@@ -1,5 +1,4 @@
---
-
- name: Checkout kernel-ci-backend code
git: repo=http://git.linaro.org/git/infrastructure/kernel-ci-backend.git
dest={{ install_base }}/{{ hostname }}
@@ -21,7 +20,18 @@
- app
- name: Install pip requirements
- pip: requirements={{ install_base }}/{{ hostname }}/requirements.txt
+ pip: requirements={{ install_base }}/{{ hostname }}/requirements.txt
+ virtualenv={{ install_base }}/.venv/{{ hostname }}
+ tags:
+ - install
+ - app
+
+- name: Fix virtualenv permissions
+ file: path={{ install_base }}/.venv/{{ hostname }}
+ state=directory
+ recurse=yes
+ owner={{ app_user }}
+ group={{ app_user }}
tags:
- install
- app
@@ -29,6 +39,9 @@
- name: Create celery log directory
file: path=/var/log/celery
state=directory
- owner=www-data
- group=www-data
+ owner={{ app_user }}
+ group={{ app_user }}
mode=0755
+ tags:
+ - install
+ - app