[Qa-jenkins-scm] [Git][qa/jenkins.debian.net][master] 2 commits: Commit the whole user .gitconfig as file, instead of calling `git config`
Mattia Rizzolo
gitlab at salsa.debian.org
Wed May 15 16:19:24 BST 2019
Mattia Rizzolo pushed to branch master at Debian QA / jenkins.debian.net
Commits:
84581f07 by Mattia Rizzolo at 2019-05-15T15:16:32Z
Commit the whole user .gitconfig as file, instead of calling `git config`
Signed-off-by: Mattia Rizzolo <mattia at debian.org>
- - - - -
c93bdaeb by Mattia Rizzolo at 2019-05-15T15:18:50Z
set a special userAgent for git, so server can more easily recognize us
Closes: #929013
Signed-off-by: Mattia Rizzolo <mattia at debian.org>
- - - - -
2 changed files:
- + jenkins-home/gitconfig
- update_jdn.sh
Changes:
=====================================
jenkins-home/gitconfig
=====================================
@@ -0,0 +1,10 @@
+[user]
+ email = jenkins at jenkins.debian.net
+ name = Jenkins
+[filter "lfs"]
+ clean = git-lfs clean -- %f
+ smudge = git-lfs smudge -- %f
+ process = git-lfs filter-process
+ required = true
+[http]
+ userAgent = jenkins.debian.net git agent
=====================================
update_jdn.sh
=====================================
@@ -636,6 +636,7 @@ fi
if [ -f jenkins-nodes-home/authorized_keys.$HOSTNAME ] ; then
cat jenkins-nodes-home/authorized_keys.$HOSTNAME | sudo tee -a /var/lib/jenkins/.ssh/authorized_keys
fi
+sudo -u jenkins cp jenkins-home/gitconfig /var/lib/jenkins/.gitconfig
sudo -u jenkins cp jenkins-home/ssh_config.in /var/lib/jenkins/.ssh/config
nodes/gen_ssh_config | sudo -u jenkins tee -a /var/lib/jenkins/.ssh/config > /dev/null
nodes/gen_known_host_file | sudo tee /etc/ssh/ssh_known_hosts > /dev/null
@@ -698,14 +699,6 @@ if [ "$HOSTNAME" = "jenkins" ] || [ "$HOSTNAME" = "jenkins-test-vm" ] ; then
explain "jenkins jobs updated."
fi
-#
-# configure git for jenkins
-#
-if [ "$(sudo su - jenkins -c 'git config --get user.email')" != "jenkins at jenkins.debian.net" ] ; then
- sudo su - jenkins -c "git config --global user.email jenkins at jenkins.debian.net"
- sudo su - jenkins -c "git config --global user.name Jenkins"
-fi
-
#
# generate the kgb-client configurations
#
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/compare/727b059fc5ed0196aa6ee08b69d31e90e8601121...c93bdaeb38768503f3f1f4c43fc5ac90f6d54963
--
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/compare/727b059fc5ed0196aa6ee08b69d31e90e8601121...c93bdaeb38768503f3f1f4c43fc5ac90f6d54963
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/qa-jenkins-scm/attachments/20190515/c701143e/attachment-0001.html>
More information about the Qa-jenkins-scm
mailing list