我在 Ubuntu 上搭建了 git 服务器, git clone 的时候一直说没有权限或者文件夹不存在, 后来我尝试用 root 登录, ls -a, 显示的文件夹都是对的. 然后我用 git 登录, ls -a, 没有找到我自己创建的文件夹, 导致 git clone 一直找不到目标文件夹. 我换成 root 用户去 git clone, 没问题. 现在我该怎么办?.
|
we000Oct 9, 2017
1
需要学习 Linux.
改文件权限, 让操作 git 的用户可以读(本地? ssh?) |
|
jinhan13789991Oct 9, 2017
2
建议使用 docker 安装 gitlab。非常快速方便
|
|
lhc70000Oct 9, 2017
3
如果不需要提供公开下载的话可以试试 gitolite
|
|
youyoumarcoOct 9, 2017
4
可以用 gitlab 代替
|
|
NorieOct 9, 2017
5
chown -R git:git yourdir
|
|
zyq2280539Oct 9, 2017
6
来来来使用 gogs,十分钟搞定 git 系统,全面兼容,要求配置非常低,比 gitlab 要求更低,树莓派都可以轻松跑起来
|
|
relaxchenOct 9, 2017
7
既然有人推荐了 GOGS,那我就推荐 Gitea 吧,搞事情
|
|
8
@we000 权限, 如下, srv 显示 git, 但是用 ssh 登录 git 账户, ls -a 里面还是没有 srv 这个文件夹.
total 68 drwx------ 8 root root 4096 Oct 8 08:57 ./ drwxr-xr-x 23 root root 4096 Jul 26 00:47 ../ -rw------- 1 root root 2441 Oct 9 01:15 .bash_history -rw-r--r-- 1 root root 3106 Oct 7 02:08 .bashrc drwx------ 2 root root 4096 Jul 26 00:49 .cache/ drwx------ 2 root root 4096 Oct 7 01:53 .gnupg/ -rw------- 1 root root 244 Oct 7 03:00 .mysql_history -rw-r--r-- 1 root root 221 Oct 7 02:10 .profile drwxr-xr-x 3 git git 4096 Oct 8 08:39 srv/ |
|
9
@Norie 看 8 楼
|
|
10
@jinhan13789991 内存只有 1g 自己搭个小服务器玩 没必要...
|
|
12
@shingle 同时我们强烈推荐承载 GitLab 运行的服务器 至少分配 4GB 的内存 给 GitLab.
我也很心痛... |