Allow openstack_hosts role to configure git safe.directory entries
This is defaulted to '*" and will be undefined when a CI specific override is subsequently merged to the openstack-ansible repository. This also includes backport of [1] which removes curl installation due to ansible bug. Also functional jobs are temporary disabled to resolve merge conflict [1] https://review.opendev.org/c/openstack/openstack-ansible-openstack_hosts/+/904403 Needed-By: https://review.opendev.org/c/openstack/openstack-ansible/+/923632 Change-Id: I1c1dc35d8d59db4ae2b6770a620d91548a8a3734 (cherry picked from commit a8d1c8268a252cd7cc5ff0ec0988b75277a0a5fe) (cherry picked from commit fb760d2902c30e517f342955efabfc3d8a11d0b8)
This commit is contained in:
parent
cf26b06f89
commit
d3186b2c14
@ -187,3 +187,6 @@ openstack_hosts_apt_pinned_packages:
|
|||||||
- package: "src:ceph"
|
- package: "src:ceph"
|
||||||
origin: "ubuntu-cloud.archive.canonical.com"
|
origin: "ubuntu-cloud.archive.canonical.com"
|
||||||
priority: 400
|
priority: 400
|
||||||
|
|
||||||
|
openstack_hosts_git_safe_directories:
|
||||||
|
- "*"
|
||||||
|
@ -164,4 +164,3 @@
|
|||||||
apply:
|
apply:
|
||||||
tags:
|
tags:
|
||||||
- openstack_hosts-config
|
- openstack_hosts-config
|
||||||
when: ansible_facts['hostname'] != 'aio1'
|
|
||||||
|
@ -29,6 +29,16 @@
|
|||||||
value: "{{ 'git/' ~ _git_version.stdout.split(' ')[2] ~ ' (osa/' ~ lookup('env', 'OSA_VERSION') ~ '/' ~ component | default('undefined') ~ ')' }}"
|
value: "{{ 'git/' ~ _git_version.stdout.split(' ')[2] ~ ' (osa/' ~ lookup('env', 'OSA_VERSION') ~ '/' ~ component | default('undefined') ~ ')' }}"
|
||||||
when: _git_version.rc == 0
|
when: _git_version.rc == 0
|
||||||
|
|
||||||
|
- name: Configure git safe directories
|
||||||
|
git_config:
|
||||||
|
scope: system
|
||||||
|
name: safe.directory
|
||||||
|
value: "{{ item }}"
|
||||||
|
with_items: "{{ openstack_hosts_git_safe_directories }}"
|
||||||
|
when:
|
||||||
|
- _git_version.rc == 0
|
||||||
|
- openstack_hosts_git_safe_directories is defined
|
||||||
|
|
||||||
- name: Write git config when git is not installed
|
- name: Write git config when git is not installed
|
||||||
template:
|
template:
|
||||||
src: gitconfig.j2
|
src: gitconfig.j2
|
||||||
|
@ -1,2 +1,9 @@
|
|||||||
[http "https://opendev.org/"]
|
[http "https://opendev.org/"]
|
||||||
userAgent = git/unknown (osa/{{ lookup('env', 'OSA_VERSION') }}/{{ component | default('undefined') }})
|
userAgent = git/unknown (osa/{{ lookup('env', 'OSA_VERSION') }}/{{ component | default('undefined') }})
|
||||||
|
|
||||||
|
{% if openstack_hosts_git_safe_directories is defined %}
|
||||||
|
[safe]
|
||||||
|
{% for dir in openstack_hosts_git_safe_directories %}
|
||||||
|
directory = {{ dir }}
|
||||||
|
{% endfor %}
|
||||||
|
{% endif %}
|
||||||
|
@ -52,7 +52,6 @@ _openstack_host_distro_packages:
|
|||||||
## Bare metal base packages
|
## Bare metal base packages
|
||||||
_openstack_host_metal_distro_packages:
|
_openstack_host_metal_distro_packages:
|
||||||
- cronie
|
- cronie
|
||||||
- /usr/bin/curl
|
|
||||||
- device-mapper-event
|
- device-mapper-event
|
||||||
- dstat
|
- dstat
|
||||||
- ebtables
|
- ebtables
|
||||||
|
@ -15,31 +15,10 @@
|
|||||||
|
|
||||||
- project:
|
- project:
|
||||||
templates:
|
templates:
|
||||||
- openstack-ansible-deploy-hosts_metal-jobs
|
# - openstack-ansible-deploy-hosts_metal-jobs
|
||||||
- openstack-ansible-deploy-hosts_distro_lxc-jobs
|
# - openstack-ansible-deploy-hosts_distro_lxc-jobs
|
||||||
- openstack-ansible-upgrade-infra_lxc-jobs
|
# - openstack-ansible-upgrade-infra_lxc-jobs
|
||||||
- check-requirements
|
- check-requirements
|
||||||
- publish-openstack-docs-pti
|
- publish-openstack-docs-pti
|
||||||
- build-release-notes-jobs-python3
|
- build-release-notes-jobs-python3
|
||||||
- openstack-ansible-linters-jobs
|
- openstack-ansible-linters-jobs
|
||||||
|
|
||||||
check:
|
|
||||||
jobs:
|
|
||||||
- openstack-ansible-deploy-hosts_metal-centos-9-stream:
|
|
||||||
voting: false
|
|
||||||
- openstack-ansible-deploy-hosts_metal-rockylinux-9:
|
|
||||||
voting: false
|
|
||||||
- openstack-ansible-deploy-hosts_distro_lxc-centos-9-stream:
|
|
||||||
voting: false
|
|
||||||
- openstack-ansible-deploy-hosts_distro_lxc-rockylinux-9:
|
|
||||||
voting: false
|
|
||||||
gate:
|
|
||||||
jobs:
|
|
||||||
- openstack-ansible-deploy-hosts_metal-centos-9-stream:
|
|
||||||
voting: false
|
|
||||||
- openstack-ansible-deploy-hosts_metal-rockylinux-9:
|
|
||||||
voting: false
|
|
||||||
- openstack-ansible-deploy-hosts_distro_lxc-centos-9-stream:
|
|
||||||
voting: false
|
|
||||||
- openstack-ansible-deploy-hosts_distro_lxc-rockylinux-9:
|
|
||||||
voting: false
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user