Answer the question
In order to leave comments, you need to log in
How to upload a local project to a private repository correctly?
Hello. Can't figure out GIT, need help.
Introductory information, there is a project that is created locally, it is spinning in laravel homestead (vagrant). I want to clone this project into a private repository on GITHUB.
What was done:
1. Created a private repository on GITHUB
2. Run the following commands in the project (local) folder:
git init
git add .
git commit -m "Первая выгрузка проекта 6 января 2020 года"
git remote add origin ssh://[email protected]:пользователь/репозиторий.git
ssh-keygen -t rsa -C "почта@yandex.ru"
git push -u origin master
ssh: Could not resolve hostname github.com:пользователь: Name or service not known
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
[email protected]:~/projects/проект$
[email protected]: Permission denied (publickey).
Answer the question
In order to leave comments, you need to log in
They already helped to figure out the reason, it was necessary to add the created keys to ssh-agent:ssh-add ~/.ssh/id_rsa
Start with a banal ping
. It seems to me that your vilgrad does not have access to the network.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question