From f7998d30a8b5c33cfa406bb04a5e6a179f220efc Mon Sep 17 00:00:00 2001 From: Andrea Dell'Amico Date: Fri, 3 May 2019 13:34:17 +0200 Subject: [PATCH] r_connector: Install the cron job that umounts the workspace under the correct user. --- smartgears/r_connector/tasks/main.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/smartgears/r_connector/tasks/main.yml b/smartgears/r_connector/tasks/main.yml index 80ab1e5..8745864 100644 --- a/smartgears/r_connector/tasks/main.yml +++ b/smartgears/r_connector/tasks/main.yml @@ -64,18 +64,22 @@ - name: Install the rconnector add users script become_user: root template: src=rusersadd.j2 dest={{ r_connector_adduserscript }} owner=root group=root mode=0555 + tags: [ 'smartgears', 'r_connector', 'r_connector_conf', 'tomcat' ] - name: Install the script that unmounts the remote workspace become_user: root template: src=rconnector_unmount dest={{ r_connector_workspace_unmount }} owner=root group=root mode=0555 + tags: [ 'smartgears', 'r_connector', 'r_connector_conf', 'tomcat' ] - name: Install the script that checks for stale workspace mounts become_user: root template: src=rconnector_check_stale_sessions dest={{ r_connector_check_stale_sessions }} owner=root group=root mode=0555 + tags: [ 'smartgears', 'r_connector', 'r_connector_conf', 'tomcat' ] - name: Install the cron job that regulary wipes out the stale workspace mounts - become: root - cron: name="Unmount the stale workspace sessions" special_time=hourly job="{{ r_connector_check_stale_sessions }} >/dev/null 2>&1" + become_user: root + cron: name="Unmount the stale workspace sessions" special_time=hourly job="{{ r_connector_check_stale_sessions }} >/dev/null 2>&1" user=root + tags: [ 'smartgears', 'r_connector', 'r_connector_conf', 'tomcat' ] - name: Crete the directory that will host the RConfiguration stuff become_user: root @@ -91,6 +95,7 @@ - name: Install /etc/R/Rprofile.site as a symlink to the svn repository become_user: root file: src={{ r_connector_rprofile_path }}/.Rprofile dest=/etc/R/Rprofile.site state=link force=yes + tags: [ 'smartgears', 'r_connector', 'r_connector_conf', 'tomcat' ] - name: Install the cron job that regulary updates the Rprofile cron: name="Update the RStudioConfiguration repo" special_time=daily job="cd {{ r_connector_rprofile_path }} ; svn update >/dev/null 2>&1"