Reputation: 708
I have given a computer within my local network, which for all practical purposes can only be controlled via BASH (Ubuntu Server 22.0.4), a static IP address, and created a Git repository on it. Should I expect to be able to clone that repo right away, or are there some tools I need before I can actually have a URL?
I have read How to find a url for a local GIT repo, and $git config --get remote.origin.url
, less .shh/config
, git remote show
do not show me anything.
I am currently only able to access this computer within my local network, it has not been registered on any DNS. I want to establish that I can use it as a local Git server before I take the following steps and get DNS registration.
I would expect that I should be able to open GitHub on another computer in the network and tell it to clone https://192.168.0.225/[something]
. I saw a mention of Gitosis. Is that sufficient to make a locally created repo accessible to other computers?
Upvotes: 0
Views: 1696
Reputation: 530833
You'll be connecting via ssh, so all you need is the IP address and the path to the repository.
git clone 192.168.0.225:/path/to/repository
should work fine. The above is shorthand for a more formal URL like
git clone ssh://192.168.0.225/path/to/repository
Upvotes: 1