summaryrefslogtreecommitdiff
path: root/roles/elevate/liquidtruth
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2019-06-10 02:46:47 +0200
committerChristian Pointner <equinox@spreadspace.org>2019-06-10 02:46:47 +0200
commit8a29a047adfa4d8ecfddc6d0f50ad9ed8aa316c9 (patch)
treea6849c71e0576908a4a46cab584919b7f6f60136 /roles/elevate/liquidtruth
parentadded node.js for liquid-truth (diff)
liquid-truth: added app user
Diffstat (limited to 'roles/elevate/liquidtruth')
-rw-r--r--roles/elevate/liquidtruth/tasks/main.yml7
-rw-r--r--roles/elevate/liquidtruth/tasks/mongodb.yml13
2 files changed, 20 insertions, 0 deletions
diff --git a/roles/elevate/liquidtruth/tasks/main.yml b/roles/elevate/liquidtruth/tasks/main.yml
index 7b1949c1..cc5dd20e 100644
--- a/roles/elevate/liquidtruth/tasks/main.yml
+++ b/roles/elevate/liquidtruth/tasks/main.yml
@@ -25,3 +25,10 @@
- name: install and configure nginx
import_tasks: nginx.yml
+
+- name: create app user
+ user:
+ name: "{{ liquidtruth_app_user }}"
+ state: present
+ append: yes
+ shell: /bin/zsh
diff --git a/roles/elevate/liquidtruth/tasks/mongodb.yml b/roles/elevate/liquidtruth/tasks/mongodb.yml
index 244d9849..8d5180ae 100644
--- a/roles/elevate/liquidtruth/tasks/mongodb.yml
+++ b/roles/elevate/liquidtruth/tasks/mongodb.yml
@@ -19,3 +19,16 @@
- mongo-tools
- python-pymongo
state: present
+
+# - name: check if admin user already exists
+# command: >
+# mongo --quiet -u root -p {{ liquidtruth_root_password }} --eval 'db.version()' admin
+# register: mongodb_root_user_check
+# changed_when: false
+# check_mode: no
+# ignore_errors: true
+# no_log: true
+
+# - name: initialize authorization
+# include_tasks: mongodb_authorization.yml
+# when: mongodb_root_user_check