Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • G gitlabhq1
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 21
    • Issues 21
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • gpt
  • large_projects
  • gitlabhq1
  • Issues
  • #4731

Closed
Open
Created Aug 07, 2013 by Administrator@rootOwner

Importing repositories from gitolite fails to setup gitlab specific hooks

Created by: walterra

Summary

Using 5-3-stable and this guide I imported repositories from a previous gitolite setup.

The import went without errors, but moving on we didn't see pushes showing up in GitLab's home stream regarding the imported repositories. Additionally newly pushed branches didn't show up in the commit-branches-dropdown, but they were present in the branches tab.

Steps to reproduce

  1. Use 5-3-stable and this guide to import repositories from a previous gitolite setup.
  2. a) Checkout and push back changes to gitlab or b) Checkout, create a new branch and push back to gitlab

Expected bevahior

  1. pushed commits should show up in home stream as notifications
  2. pushed new branches should show up in homestream and commit-branch-dropdown

Workaround

Turns out gitlab is not able to overwrite the hooks already in place by gitolite (post-receive & update).

We ended up batch updating dozens of already imported repositories like:

$ cd /home/git/repositories
$ find . -type d -iname "hooks" -exec rm {}/post-receive \;
$ find . -type d -iname "hooks" -exec rm {}/update \;
$ find . -type d -iname "hooks" -exec ln -s /home/git/gitlab-shell/hooks/post-receive {}/post-receive \;
$ find . -type d -iname "hooks" -exec ln -s /home/git/gitlab-shell/hooks/update {}/update \;

I guess this might also affect imported repositories with other costumized hooks.

Assignee
Assign to
Time tracking