From 5eac7a8c1fe31b8651480e5cd8f8d2cc8fc85068 Mon Sep 17 00:00:00 2001 From: Andrea Dell'Amico Date: Fri, 14 Dec 2018 16:46:09 +0100 Subject: [PATCH] Fix the virtuoso task that changes the default password. --- virtuoso/defaults/main.yml | 5 +++-- virtuoso/tasks/virtuoso-dba-user.yml | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/virtuoso/defaults/main.yml b/virtuoso/defaults/main.yml index 667a0370..3880f067 100644 --- a/virtuoso/defaults/main.yml +++ b/virtuoso/defaults/main.yml @@ -8,14 +8,15 @@ virtuoso_version: 7 virtuoso_user: virtuoso virtuoso_base_dir: '/var/lib/virtuoso-opensource-{{ virtuoso_version }}' virtuoso_db_dir: '{{ virtuoso_base_dir }}/db' -virtuoso_error_log: '{{ virtuoso_db_dir }}/virtuoso.log' +virtuoso_dumps_dir: '{{ virtuoso_base_dir }}/dumps' virtuoso_log_dir: '/var/log/virtuoso-opensource-{{ virtuoso_version }}' +virtuoso_error_log: '{{ virtuoso_log_dir }}/virtuoso.log' virtuoso_server_port: 1111 virtuoso_ssl_server_port: 2111 virtuoso_http_server: 8890 virtuoso_http_server_root: '/var/lib/virtuoso-opensource-{{ virtuoso_version }}/vsp' virtuoso_vad_install_dir: '/usr/share/virtuoso-opensource-{{ virtuoso_version }}/vad' -virtuoso_dirsallowed: '., {{ virtuoso_vad_install_dir }}/, {{ virtuoso_log_dir }}/' +virtuoso_dirsallowed: '., {{ virtuoso_vad_install_dir }}/, {{ virtuoso_log_dir }}/, {{ virtuoso_dumps_dir }}/' virtuoso_isql: /usr/bin/isql-vt #virtuoso_dba_pwd: set it in a vault file diff --git a/virtuoso/tasks/virtuoso-dba-user.yml b/virtuoso/tasks/virtuoso-dba-user.yml index 5504b873..667a1281 100644 --- a/virtuoso/tasks/virtuoso-dba-user.yml +++ b/virtuoso/tasks/virtuoso-dba-user.yml @@ -1,11 +1,11 @@ --- - name: Create the isql script to change the dba default password - copy: content="set password dba {{ virtuoso_dba_pwd }};\n" dest={{ virtuoso_db_dir }}/.isql_change_dba_pwd owner={{ virtuoso_user }} group={{ virtuoso_user }} mode=0400 + copy: content="set password dba {{ virtuoso_dba_pwd }};\n" dest={{ virtuoso_db_dir }}/.isql_change_dba.sql owner={{ virtuoso_user }} group={{ virtuoso_user }} mode=0400 when: virtuoso_dba_pwd is defined tags: [ 'virtuoso', 'virtuoso_conf' ] - name: Change the default dba password - shell: '{{ virtuoso_isql }} -H localhost -S {{ virtuoso_server_port }} -U dba -P dba < {{ virtuoso_db_dir }}/.isql_change_dba_pwd ; touch {{ virtuoso_db_dir }}/.dba_changed_password' + shell: '{{ virtuoso_isql }} localhost:{{ virtuoso_server_port }} dba dba {{ virtuoso_db_dir }}/.isql_change_dba.sql -i arg1 && touch {{ virtuoso_db_dir }}/.dba_changed_password' args: creates: '{{ virtuoso_db_dir }}/.dba_changed_password'