Made directory variables for /etc/systemd/system , /etc/cron.d , /usr/local/bin
This commit is contained in:
@ -31,7 +31,7 @@
|
||||
- name: Ensure matrix-goofys.service installed
|
||||
template:
|
||||
src: "{{ role_path }}/templates/goofys/systemd/matrix-goofys.service.j2"
|
||||
dest: "/etc/systemd/system/matrix-goofys.service"
|
||||
dest: "{{ matrix_systemd_path }}/matrix-goofys.service"
|
||||
mode: 0644
|
||||
register: matrix_goofys_systemd_service_result
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
- name: Check existence of matrix-goofys service
|
||||
stat:
|
||||
path: "/etc/systemd/system/matrix-goofys.service"
|
||||
path: "{{ matrix_systemd_path }}/matrix-goofys.service"
|
||||
register: matrix_goofys_service_stat
|
||||
|
||||
- name: Ensure matrix-goofys is stopped
|
||||
@ -13,7 +13,7 @@
|
||||
|
||||
- name: Ensure matrix-goofys.service doesn't exist
|
||||
file:
|
||||
path: "/etc/systemd/system/matrix-goofys.service"
|
||||
path: "{{ matrix_systemd_path }}/matrix-goofys.service"
|
||||
state: absent
|
||||
when: "matrix_goofys_service_stat.stat.exists"
|
||||
|
||||
|
@ -28,4 +28,4 @@
|
||||
when: "start_result.changed"
|
||||
|
||||
- name: Register user
|
||||
shell: "/usr/local/bin/matrix-synapse-register-user {{ username }} {{ password }} {{ '1' if admin == 'yes' else '0' }}"
|
||||
shell: "{{ matrix_local_bin_path }}/matrix-synapse-register-user {{ username }} {{ password }} {{ '1' if admin == 'yes' else '0' }}"
|
||||
|
@ -90,7 +90,7 @@
|
||||
- name: Ensure matrix-synapse.service installed
|
||||
template:
|
||||
src: "{{ role_path }}/templates/synapse/systemd/matrix-synapse.service.j2"
|
||||
dest: "/etc/systemd/system/matrix-synapse.service"
|
||||
dest: "{{ matrix_systemd_path }}/matrix-synapse.service"
|
||||
mode: 0644
|
||||
register: matrix_synapse_systemd_service_result
|
||||
|
||||
@ -102,5 +102,5 @@
|
||||
- name: Ensure matrix-synapse-register-user script created
|
||||
template:
|
||||
src: "{{ role_path }}/templates/synapse/usr-local-bin/matrix-synapse-register-user.j2"
|
||||
dest: "/usr/local/bin/matrix-synapse-register-user"
|
||||
dest: "{{ matrix_local_bin_path }}/matrix-synapse-register-user"
|
||||
mode: 0750
|
||||
|
@ -1,6 +1,6 @@
|
||||
- name: Check existence of matrix-synapse service
|
||||
stat:
|
||||
path: "/etc/systemd/system/matrix-synapse.service"
|
||||
path: "{{ matrix_systemd_path }}/matrix-synapse.service"
|
||||
register: matrix_synapse_service_stat
|
||||
|
||||
- name: Ensure matrix-synapse is stopped
|
||||
@ -13,7 +13,7 @@
|
||||
|
||||
- name: Ensure matrix-synapse.service doesn't exist
|
||||
file:
|
||||
path: "/etc/systemd/system/matrix-synapse.service"
|
||||
path: "{{ matrix_systemd_path }}/matrix-synapse.service"
|
||||
state: absent
|
||||
when: "matrix_synapse_service_stat.stat.exists"
|
||||
|
||||
|
@ -45,4 +45,4 @@
|
||||
register: password_hash
|
||||
|
||||
- name: Update user password hash
|
||||
shell: "/usr/local/bin/matrix-postgres-update-user-password-hash {{ username }} '{{ password_hash.stdout }}'"
|
||||
shell: "{{ matrix_local_bin_path }}/matrix-postgres-update-user-password-hash {{ username }} '{{ password_hash.stdout }}'"
|
||||
|
Reference in New Issue
Block a user