我运行的是 git服务器。
我的大多数用户都在运行git的3个版本中的1个。
git 1.7.1 (centos用户)
git 1.7.9 (其他所有人)
git 1.8.4 (mac用户)
一些用户意外地以root用户的身份提交和推送代码。我需要阻止来自这些用户的提交。
我的pre-commit钩子如下所示:
#!/bin/bash
if [[ $GIT_AUTHOR_NAME == 'root' ]]
then
echo "If you commit as root, you're gonna have a bad time";
e
似乎一些夜间Jenkins作业间歇性地失败,所以它们只是偶尔失败。控制台输出如下:
Started by timer
Checking out git ssh://git@gitlab.domain.com:2222/repo-here.git into /opt/jenkins/home/workspace/job_name@script to read Jenkinsfile
Wiping out workspace first.
Cloning the remote Git repository
Cloning repository ssh://git@gitlab.domain.com
为了克隆一个大仓库,我得到了:
remote: fatal: Out of memory, malloc failed (tried to allocate 190135255 bytes)
看到客户端中可能存在~/.gitconfig或.git/config的配置,但似乎是服务器在传递它之前能够生成这么大的文件,我可以在服务器上配置最大malloc的大小吗?
我系统的服务器是
pi@domP3: ~$ git --version
git version 2.11.0
pi@domP3: ~$ lsb_release -a
No LSB modules are available.
Distr
对于基于产品的GIT存储库,其中有用于维护、测试和未来开发的分支,如何控制用户对这些分支的访问。通过访问,我的意思是,即使其他人可能从中读到,他们也不应该在不经意间推动对回购的修改。
例如,
A - B - C - D - E - F -> master
| | |
V1 V2' exp
|
V2
"B“是带有标记V1的分支使用的提交--用于发布产品的版本。只有支持/维护工程师才能接触到这一点。
C用于最近冻结的预发布产品V2‘,应该只允许关键的显示停止错误修复,因此只有某些开发人员和测试团队才能访