diff --git a/README.md b/README.md index 78e7c41..4e90d9c 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,8 @@ Role Variables -------------- - `im_secret_key`: optional Secret Key for Django app, defaults to random 56char string recreated on every run (This will invalidated current open sessions) +- `im_user`: user running the app, defaults to 'im' (this user will be created) +- `im_home`: path to install the im app in, defaults to /home/im (this path will be created) - `im_domain`: the domain this app will run on (Needed for django's ALLOWED_HOSTS), default localhost - `im_db_name`: database name, defaults to 'im' - `im_db_user`: database user, defaults to 'im' diff --git a/tasks/main.yml b/tasks/main.yml index fdb667a..442149f 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -52,14 +52,6 @@ owner: "{{ im_user }}" mode: 0600 notify: "Restart im" - vars: - - im_secret_key: "{{ lookup('password', im_home + '/.imsecretfile chars=ascii_letters' length=56) }}" - - im_domain: 'localhost' - - im_db_name: 'im' - - im_db_user: 'im' - - im_db_server: 'localhost' - - im_db_port: '5432' - - name: 'migrate django im app' django_manage: diff --git a/vars/main.yml b/vars/main.yml index b32e617..a1a19e5 100644 --- a/vars/main.yml +++ b/vars/main.yml @@ -1,2 +1,12 @@ --- -# vars file for im \ No newline at end of file +# vars file for im +im_home: /home/im +im_secret_key: "{{ lookup('password', im_home + '/.imsecretfile chars=ascii_letters' length=56) }}" +im_domain: 'localhost' +im_db_name: 'im' +im_db_user: 'im' +im_user: 'im' +im_db_server: 'localhost' +im_db_port: '5432' + +