Reputation: 472
I'm new to git but I've had things flowing fairly well until I tried pushing to my private server directly from my local machine using SSH. My local config, using an absolute path is the following:
[remote "origin"]
url = ssh://j@***.com:52836/home/j/www/wc.git
fetch = +refs/heads/*:refs/remotes/origin/*
My server's config is set as bare. When I push, after passwording in, I get the following error: stdin: is not a tty fatal: '/home/j/www/wc.git' does not appear to be a git repository fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
I've cloned both my local repo and my private server from my bitbucket account. I want to be able to push from my local machine to both (using the pushurl) - but I simply cannot find my private server's repo. However, I can update my private server and bit bucket AND I can update my local machine and bit bucket. I simply cannot connect my local machine and private server (which is my production server). My private server repo is located at /Users/mark/sites/wc/. The .git folder is inside the wc folder.
I've tried Git "does not appear to be a git repository" and How to check the validity of a remote git repository URL? with no luck.
Upvotes: 0
Views: 191
Reputation: 80921
Some sort of path or bare repo confusion appeared to be at work here. Resolution was to recreate the private repo ensuring that it was a bare repo and to point the remote url
config entry at the correct path.
Upvotes: 1