-2

I'm new to Git and I have an intranet set up with Gitlab. I have created a Laravel project on a Linux server and have successfully pushed the files to my Gitlab project. However, because the server is not internet facing, the I also have to develop the application on WAMP on my PC, so that Composer can pull the necessary packages I need. My question is - when I pull the application to my PC from Gitlab, how do I set up the SSH side of things? Do I use the same key that I use on the Linux server and, if so, how do I get that registered on my PC?

YarlanZey
  • 1
  • 4

1 Answers1

0

By your question i understand you want to clone the repository and then get your project started in your system.

There is a simple solution to get started. Before cloning the repository you need following things to be installed and made ready:

  1. Git
  2. Gitlab Account
  3. Composer

Now , you need to go into your git-bash or any terminal that you use for git commands and type the following command:

$ ssh-keygen

This generates a new ssh-key for your system, or if you already have one for your system you could use:

$ cat < ~/.ssh/id_rsa.pub

This copies your ssh-key to your terminal.

Now, you need to open your gitlab account and add the ssh-key to your account.

http://<your-server-ip/domain>/profile/keys

After addition of the ssh-keys to your server you now can clone the repository to your system and use it.

Note :

You cannot use same ssh-key on different gitlab accounts.

To use that you could follow this answer:

https://stackoverflow.com/a/30320641/3887342

Hope this helps you.

Community
  • 1
  • 1
PaladiN
  • 4,625
  • 8
  • 41
  • 66