Skip to content
Snippets Groups Projects
management.md 612 B
Newer Older
# Managing mirrored repositories

Sam Gleske's avatar
Sam Gleske committed
A short overview of managing mirrored repositories.  This assumes you have already [installed gitlab-mirrors](installation.md).

### Create a mirror

    su - gitmirror
Sam Gleske's avatar
Sam Gleske committed
    cd gitlab-mirrors
    ./add_mirror.sh project_name http://example.com/repository.git

### Update a mirror

    su - gitmirror
Sam Gleske's avatar
Sam Gleske committed
    cd gitlab-mirrors
    ./update_mirror.sh project_name

### Update all known mirrors

    su - gitmirror
Sam Gleske's avatar
Sam Gleske committed
    cd gitlab-mirrors
    ./git-mirrors.sh

Updating all known mirrors is also meant to be used with `crontab`.

Sam Gleske's avatar
Sam Gleske committed
    @hourly /home/gitmirror/gitlab-mirrors/git-mirrors.sh