forked from ISTI-ansible-roles/ansible-roles
library/roles/d4s_user_services_perms: Fix the generation of the start/stop scripts. Now the multiuser option is supported.
This commit is contained in:
parent
a8849d5826
commit
13d224e336
|
@ -4,8 +4,8 @@
|
||||||
tags: [ 'tomcat', 'd4science', 'sudo' ]
|
tags: [ 'tomcat', 'd4science', 'sudo' ]
|
||||||
|
|
||||||
- name: Install the script that allows the tomcat user to start and stop the service without using the full path
|
- name: Install the script that allows the tomcat user to start and stop the service without using the full path
|
||||||
template: src={{ item }}.j2 dest={{ d4science_user_home }}/{{ item }} owner={{ d4science_user }} group={{ d4science_user }} mode=0755
|
template: src={{ item.1 }}.j2 dest={{ item.0.user_home }}/{{ item.1 }} owner={{ item.0.user }} group={{ item.0.user }} mode=0755
|
||||||
with_items:
|
with_nested:
|
||||||
- startContainer.sh
|
- '{{ tomcat_m_instances }}'
|
||||||
- stopContainer.sh
|
- [ 'startContainer.sh', 'stopContainer.sh' ]
|
||||||
tags: [ 'tomcat', 'd4science', 'sudo' ]
|
tags: [ 'tomcat', 'd4science', 'sudo' ]
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
sudo /etc/init.d/tomcat-instance-{{ http_port }} start
|
sudo /etc/init.d/tomcat-instance-{{ item.0.http_port }} start
|
||||||
|
|
||||||
exit $?
|
exit $?
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
sudo /etc/init.d/tomcat-instance-{{ http_port }} stop
|
sudo /etc/init.d/tomcat-instance-{{ item.0.http_port }} stop
|
||||||
|
|
||||||
exit $?
|
exit $?
|
||||||
|
|
Loading…
Reference in New Issue