mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-22 22:30:23 +00:00
ci: allow /opt/build for git repository when deploying jobs
When Jenkins Jobs have been modified, they should get deployed in the Jenkins environment. This seems to fail with the following error: ``` Initialized empty Git repository in /opt/build/.git/ fatal: detected dubious ownership in repository at '/opt/build' To add an exception for this directory, call: git config --global --add safe.directory /opt/build ``` By marking /opt/build as a safe directory in the global git configuration file, this problem should not occur anymore. Signed-off-by: Niels de Vos <ndevos@redhat.com>
This commit is contained in:
parent
f7ba14b2ed
commit
234471af33
@ -11,6 +11,7 @@ fail() {
|
|||||||
# exit in case a command fails
|
# exit in case a command fails
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
git config --global --add safe.directory ${PWD}
|
||||||
git init .
|
git init .
|
||||||
git remote add origin "${GIT_REPO}"
|
git remote add origin "${GIT_REPO}"
|
||||||
git fetch origin "${GIT_REF}"
|
git fetch origin "${GIT_REF}"
|
||||||
|
Loading…
Reference in New Issue
Block a user