-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Description
Versions
downloaded gitbucket from here:
wget https://github.com/gitbucket/gitbucket/releases/download/4.41.0/gitbucket.war
java -version
openjdk version "11.0.24" 2024-07-16
OpenJDK Runtime Environment (build 11.0.24+8-post-Ubuntu-1ubuntu320.04)
OpenJDK 64-Bit Server VM (build 11.0.24+8-post-Ubuntu-1ubuntu320.04, mixed mode, sharing)
Deployment mode
Running gitbucket as a linux service with the following service line:
ExecStart=/usr/bin/java -jar /opt/gitbucket/gitbucket.war --host=0.0.0.0 --port=8080 --gitbucket.home=/opt/gitbucket/gitbucket-data
Problem description:
Create a new project using the webUI, and select 'import', to import an existing project (project_name) from github.
After creating, go to a remote machine and try and clone using the URL, e.g.:
and you will receive the message:
warning: You appear to have cloned an empty repository.
To show that the remote repository is NOT empty, you can clone it using ssh (provided you have ssh setup), like so:
git clone ssh://root@my_server:22/path_to_gitbucket_data/repositories/a_user/project_name.git
and git will complain that you need to run the following command on the server due to 'dubious' ownership:
git config --global --add safe.directory /opt/gitbucket/gitbucket-data/repositories/johnpearcey/dub_jkp.git
after doing that, you can run git clone with ssh again and the project will be cloned correctly.
The command 'git config --global --add safe.directory...' dod not fix the failure of the http issue which continues to clone an empty repository.
So it seems that the import from github was successful but clone over http fails.
The logs provide no output:
journalctl -f -u gitbucket.service