diff --git a/doc/source/general-jobs.rst b/doc/source/general-jobs.rst index 314e093bd..08b95c8c9 100644 --- a/doc/source/general-jobs.rst +++ b/doc/source/general-jobs.rst @@ -5,3 +5,4 @@ General Purpose Jobs .. zuul:autojob:: unittests .. zuul:autojob:: multinode .. zuul:autojob:: run-test-command +.. zuul:autojob:: upload-git-mirror diff --git a/playbooks/upload-git-mirror/run.yaml b/playbooks/upload-git-mirror/run.yaml new file mode 100644 index 000000000..7b9a6af9a --- /dev/null +++ b/playbooks/upload-git-mirror/run.yaml @@ -0,0 +1,4 @@ +- name: Mirror git repository to a remote git server + hosts: all + roles: + - upload-git-mirror diff --git a/zuul.yaml b/zuul.yaml index 6de795cfe..389dfe85e 100644 --- a/zuul.yaml +++ b/zuul.yaml @@ -50,6 +50,34 @@ nodeset: nodes: [] +- job: + name: upload-git-mirror + description: | + Mirrors a tested project repository to a remote git server. + + .. zuul:jobvar:: git_mirror_credentials + :type: dict + + This is expected to be a Zuul Secret with these keys: + + .. zuul:jobvar:: user + + SSH user for the remote git repository + + .. zuul:jobvar:: host + + SSH host for the remote git repository + + .. zuul:jobvar:: key + + Literal private key contents. + Should start with something like ``-----BEGIN RSA PRIVATE KEY-----``. + + .. zuul:jobvar:: git_mirror_repository + + Path of the remote git repository + run: playbooks/upload-git-mirror/run.yaml + - job: name: tox parent: unittests