Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jochumdev/vcs-mirrors
Mirror your VCS with ease
https://github.com/jochumdev/vcs-mirrors
gitlab gitlab-mirror mirroring replication
Last synced: 4 days ago
JSON representation
Mirror your VCS with ease
- Host: GitHub
- URL: https://github.com/jochumdev/vcs-mirrors
- Owner: jochumdev
- License: mit
- Created: 2018-04-21T09:20:52.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2020-01-14T08:18:39.000Z (about 5 years ago)
- Last Synced: 2024-11-16T09:35:02.591Z (2 months ago)
- Topics: gitlab, gitlab-mirror, mirroring, replication
- Language: Python
- Homepage:
- Size: 43 KB
- Stars: 3
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- Changelog: CHANGELOG.rst
- License: LICENSE
Awesome Lists containing this project
README
.. image:: https://badge.fury.io/py/vcs-mirrors.svg
:target: https://badge.fury.io/py/vcs-mirrors.. image:: https://img.shields.io/pypi/pyversions/vcs-mirrors.svg
:target: https://pypi.python.org/pypi/vcs-mirrorsvcs-mirrors
===========A python-only clone of https://github.com/samrocketman/gitlab-mirrors/ with a YAML config file.
Requirements
------------- Python 3.5+ (Debian Stretch+, Ubuntu Xenial+)
- virtualenv if you don't want to mess with System Python
- git-remote-bzr https://github.com/felipec/git-remote-bzr for Bazaar supportFeatures
--------* Mirror different types of source repositories: Bazaar, Git, Subversion. Mirror all into git.
* GitLab mirror adding.
* When adding a mirror if the project doesn't exist in GitLab it will be auto-created.
* Set project creation defaults (e.g. issues enabled, wiki enabled, etc.)
* Github mirror adding.
* Same as with Gitlab.
* mirror anything to Git (not just Gitlab and Github).
* Update a single mirror.
* Update all known mirrors.Installation
++++++++++++On Debian
---------For Bazaar support:
.. code:: bash
$ apt install git-remote-bzr
Install into a virtualenv:
.. code:: bash
$ virtualenv -p /usr/bin/python3 --no-site-packages venv
$ venv/bin/pip install "vcs-mirrors[gitlab,github]"Then copy vcs-mirrors.yaml.example into your current-working-directory:
.. code:: bash
$ cp venv/lib/python3.6/site-packages/vcs-mirrors/vcs-mirrors.yaml.sample vcs-mirrors.yaml
Edit it for your needs.
Usage
+++++
.. code:: bashvenv/bin/vcs-mirrors -h
venv/bin/vcs-mirrors add -hadd examples:
-------------This one try to create a repo "pcdummy/proxmox-dockerfiles" on git.lxch.eu - the identifier must be unique in the config file:
.. code:: bash
$ vcs-mirrors add me/p-dockerfiles https://github.com/pcdummy/proxmox-dockerfiles.git git.lxch.eu:pcdummy/proxmox-dockerfiles
This doesn't:
.. code:: bash
$ vcs-mirrors add me/p-dockerfiles https://github.com/pcdummy/proxmox-dockerfiles.git [email protected]:pcdummy/proxmox-dockerfiles.git
Full mirroring include "prune" and "force" pull/push:
.. code:: bash
$ vcs-mirrors add -f -p me/p-dockerfiles https://github.com/pcdummy/proxmox-dockerfiles.git git.lxch.eu:pcdummy/proxmox-dockerfiles
If you give an host as target "add" creates the repo on the host and translates it to a git URL else add does nothing else than adding the params to your configuration file.
Development
+++++++++++.. code:: bash
$ pip install -e ."[development,gitlab,github]"
Keywords
++++++++gitlab github sync mirror vcs-mirror bazaar