From: Kyr Shatskyy Date: Thu, 14 Mar 2019 18:00:03 +0000 (+0100) Subject: teuthology: use variable for user name X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F448%2Fhead;p=ceph-cm-ansible.git teuthology: use variable for user name Signed-off-by: Kyr Shatskyy --- diff --git a/roles/teuthology/tasks/main.yml b/roles/teuthology/tasks/main.yml index d5cdb28a..3a276f3d 100644 --- a/roles/teuthology/tasks/main.yml +++ b/roles/teuthology/tasks/main.yml @@ -31,10 +31,10 @@ - name: Ship teuthology user's crontab update script template: src: update-crontab.sh - dest: /home/teuthology/bin/update-crontab.sh + dest: "/home/{{ teuthology_scheduler_user }}/bin/update-crontab.sh" mode: 0775 - owner: teuthology - group: teuthology + owner: "{{ teuthology_scheduler_user }}" + group: "{{ teuthology_scheduler_user }}" tags: - crontab diff --git a/roles/teuthology/templates/teuthology-worker.init b/roles/teuthology/templates/teuthology-worker.init index 590b4616..63d9ec90 100644 --- a/roles/teuthology/templates/teuthology-worker.init +++ b/roles/teuthology/templates/teuthology-worker.init @@ -35,7 +35,7 @@ export NWORKERS=20 [ -f /etc/default/teuthology ] && source /etc/default/teuthology -user=${TEUTHOLOGY_USERNAME:-teuthworker} +user=${TEUTHOLOGY_USERNAME:-"{{ teuthology_execution_user }}"} export HOME=/home/$user export WORKER_HOME=$HOME/src/teuthology_master #/usr/share/nginx/html