From e8b82ac4de8eff76987bbb4f3d849fdea1692622 Mon Sep 17 00:00:00 2001 From: "James E. Blair" Date: Wed, 30 Aug 2017 15:51:55 -0700 Subject: [PATCH] Fix error in mirror-workspace-git-repos The project src_dir contains 'src/', so use work_root instead of src_root. Change-Id: I3017dded1a8baf7fcad0b47a759dfc9f7355d0b1 --- roles/mirror-workspace-git-repos/tasks/main.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/roles/mirror-workspace-git-repos/tasks/main.yaml b/roles/mirror-workspace-git-repos/tasks/main.yaml index 5b4dce356..052fac2f6 100644 --- a/roles/mirror-workspace-git-repos/tasks/main.yaml +++ b/roles/mirror-workspace-git-repos/tasks/main.yaml @@ -1,14 +1,14 @@ - name: Synchronize src repos to workspace directory command: "git push --mirror git+ssh://{{ ansible_user }}@{{ ansible_host }}/{{ ansible_user_dir }}/{{ item.src_dir}}" args: - chdir: "{{ zuul.executor.src_root }}/{{ item.src_dir }}" + chdir: "{{ zuul.executor.work_root }}/{{ item.src_dir }}" with_items: "{{ zuul.projects }}" delegate_to: localhost - name: Determine local HEAD shell: "git status |head -1 |awk '{ print $NF }'" args: - chdir: "{{ zuul.executor.src_root }}/{{ item.src_dir }}" + chdir: "{{ zuul.executor.work_root }}/{{ item.src_dir }}" with_items: "{{ zuul.projects }}" delegate_to: localhost register: statuses @@ -16,7 +16,7 @@ - name: Checkout local HEAD on remote command: "git checkout {{ item.1 }}" args: - chdir: "{{ zuul.executor.src_root }}/{{ item.0.src_dir }}" + chdir: "{{ zuul.executor.work_root }}/{{ item.0.src_dir }}" with_together: - "{{ zuul.projects }}" - "{{ statuses }}"