tree: 8f578ad715ec0186740c756258871ef732b79574 [path history] [tgz]
  1. tools/
  2. Dockerfile
  3. fetch-config.example.yaml
  4. README.md
container-images/fetch-job/README.md

FetchJob container image

Container to run a job that fetches from remote repositories to corresponding local repositories. Thi can be used to create copies of repositories hosted on other git servers in the local Gerrit. This is useful for backing up repositories or to have a copy of branches of a project that was forked in the local Gerrit.

Content

  • base image
  • fetch-job.sh: script executing the fetches

Start

  • execution of the provided fetch-job.sh

Configuration

remotes:
- name: example
  url: https://example.com
  timeout: 5m
  fetch:
  - remoteRepo: project1
  - remoteRepo: project2
    localRepo: local/project2
  - remoteRepo: project3
    localRepo: local/project3
    refSpec: "+refs/heads/*:refs/heads/remote/*"

You will need to mount the credentials used to authenticate with remote servers to the container, e.g. by providing a .netrc file at home/gerrit/.netrc.