I had my projects hosted on GitHub and wanted to move this projects to my own instance. So after installing GitLab on my own server I started moving the projects.
Moving a project from GitHub to GitLab is quite easy. When creating a project in GitLab you have the chance to import a project from different sources. One of this sources is GitHub. For this the GitLab instance has to be configured to allow imports from GitHub (under Administration/Settings/Visibility and access controls).
After selecting the import from GitHub a personal access token is requested. This is has to be created at GitHub before starting the import.
To create a Personal Access Token log in to GitHub and navigate to User Settings > Developer Settings > Personal Access Token.
The Personal Access Token should have full access to your repository.
After entering the Personal Access Token all repositories you have access to are shown.
Now select the repository or repositories to import and the place where to import. You can import any number of repositories in the mask.
If you want to import GitHub projects in a regular fashion you can use OmniAuth to connect your GitLab account with GitHub — I only use the Personal Access Token.
The advantage of importing a GitHub project this way is that — besides the repository itself — all issues and your wiki are also imported from GitHub.
Next I will set up a docker registry and use this in GitLab for my own docker images.
- Part 1 – Installation
- Part 2 – Configure NGINX reverse proxy
- Part 3 – Configure gitlab-runner
- Part 4 – Import GitHub project
- Part 5 – Configure Docker Registry
- Part 6 – Configure NGINX for Pages