From d496405f667a6c90836d873c6c0840c4e8fb79af Mon Sep 17 00:00:00 2001 From: L3D Date: Sat, 12 Nov 2022 23:52:49 +0100 Subject: [PATCH] improve role by adding debugging options --- tasks/migrate.yml | 20 ++++++++++++++++++++ vars/main.yml | 2 +- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/tasks/migrate.yml b/tasks/migrate.yml index d8b5001..f626ea8 100644 --- a/tasks/migrate.yml +++ b/tasks/migrate.yml @@ -5,6 +5,12 @@ chdir: "{{ etebase__user_home }}/etebase_{{ etebase_version_target }}" cmd: "{{ etebase__venv }}/bin/python3 ./manage.py migrate" changed_when: _etebase_download.changed or _etebase_config.changed + register: _etebase_migrate + +- name: Print output of python3 manage.py migrate + ansible.builtin.debug: + verbosity: 1 + msg: "{{ _etebase_migrate.result }}" - name: Create static files become: true @@ -12,6 +18,12 @@ chdir: "{{ etebase__user_home }}/etebase_{{ etebase_version_target }}" cmd: "{{ etebase__venv }}/bin/python3 ./manage.py collectstatic" creates: "{{ etebase__global_static_root }}/admin" + register: _etebase_collectstatic + +- name: Print output of python3 manage.py collectstatic + ansible.builtin.debug: + verbosity: 1 + msg: "{{ _etebase_collectstatic.result }}" - name: "Fix File Permissions for secret directory" become: true @@ -36,3 +48,11 @@ mode: 'u=rwX,g=rX,o=rX' with_items: - "{{ etebase__global_static_root }}" + +- name: Print hint how to create admin User + ansible.builtin.debug: + msg: | + To create a admin user, run + 'cd {{ etebase__user_home }}/etebase_{{ etebase_version_target }}; + {{ etebase__venv }}/bin/python3 ./manage.py createsuperuser' + as priviledged user. diff --git a/vars/main.yml b/vars/main.yml index 71b6123..402a3c5 100644 --- a/vars/main.yml +++ b/vars/main.yml @@ -3,5 +3,5 @@ etebase__repo: 'https://github.com/etesync/server.git' etebase__repo_api: 'https://api.github.com/repos/etesync/server/tags' # versionscheck -playbook_version_number: 7 # should be a integer +playbook_version_number: 8 # should be a integer playbook_version_path: 'role-etebase'