Drop privileges before running the git clone script

This causes the git repository files to be owned by the same user
as the one used by lsyncd to connect to the other repo servers.

Change-Id: I004e3bbef182b4dc6f18df5b9424190288f5e47d
Closes-Bug: #1620765
Depends-On: I3d974d578f3e2323415e36c40efa48036b517468
This commit is contained in:
Paulo Matias 2016-09-06 15:12:19 -03:00
parent 100d07404e
commit dec3ab443b
3 changed files with 8 additions and 0 deletions

View File

@ -22,6 +22,8 @@
- name: Run clone process script
shell: "bash /opt/op-clone-script.sh"
become: yes
become_user: "{{ repo_build_service_user_name }}"
tags:
- repo-clone-repos

View File

@ -25,12 +25,16 @@
dest: "/var/www/repo/openstackgit/keystone"
clone: yes
update: yes
become: yes
become_user: "{{ repo_build_service_user_name }}"
- name: Pre-cache the tempest git repository
git:
repo: "https://git.openstack.org/openstack/tempest"
dest: "/var/www/repo/openstackgit/tempest"
clone: yes
update: yes
become: yes
become_user: "{{ repo_build_service_user_name }}"
- name: Intentionally set the keystone repo remote origin to github
shell: "git remote set-url origin https://github.com/openstack/keystone.git"
args:

View File

@ -17,6 +17,8 @@ openstack_release: testing
repo_build_release_tag: "{{ openstack_release }}"
galera_client_drop_config_file: false
repo_build_service_user_name: "nginx"
# Test data input for upper constraints validation
repo_build_upper_constraints_overrides:
- elasticsearch<2.1.0