Skip to content
This repository was archived by the owner on Sep 3, 2024. It is now read-only.

Commit d36d9d1

Browse files
authored
Readme Update
1 parent 401406a commit d36d9d1

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

README.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,23 @@ Also make sure you have Github and Gitlab ssh installed.
1717
```
1818
* Edit mirror.php and set appropriate git ssh config for repository on line number 19 and 22
1919

20+
* Now everything is in place, but because gitlab keeps it's own "special" branches in place, you might get these kinds of errors:
21+
22+
```bash
23+
! [remote rejected] refs/keep-around/09c68d4f76f68041438040e3bb4316d5ca1d5135 -> refs/keep-around/09c68d4f76f68041438040e3bb4316d5ca1d5135 (deny updating a hidden ref)
24+
```
25+
- We need to filter those out of the branches we _do_ want to mirror. In order to do that we edit the `config` file again.
26+
27+
- We should replace `fetch = +refs/*:refs/*` which basically says, everything, and just select `tags`, `branches` and `head`
28+
29+
```bash
30+
[remote "mirror"]
31+
url = git@gitlab.external:reponame.git
32+
push = +refs/heads/*:refs/heads/*
33+
push = +refs/tags/*:refs/tags/*
34+
mirror = true
35+
```
36+
2037
## Any cause of failure on self-hosted server:
2138

2239
- The public ssh key of www-data should have read and write access to source repository.

0 commit comments

Comments
 (0)