Scripts to mirror Gitea repository to GIT mirrors
This repository has been archived on 2023-11-10. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
Go to file
Sandro Santilli 8f9d22f2f1 Disable gitlab and github mirrors, now done by Gitea directly 2023-03-21 22:56:53 +01:00
.gitignore Add ignores 2017-05-14 12:14:01 +02:00
Makefile Update Makefile 2019-10-27 19:52:49 +01:00
README.md Add a note about manual sync helping with ssh key verification 2017-05-22 10:11:49 +02:00
git-sync.sh Disable gitlab and github mirrors, now done by Gitea directly 2023-03-21 22:56:53 +01:00
update-daemon Tweak mirroring script to do git-git mirror 2019-10-27 19:50:36 +01:00
update-mirrors.cgi Show a more meaningful message about mirroring script notification 2019-11-15 11:41:21 +01:00

README.md

Scripts to sync code between repositories

Tested successfully with:

  • git-svn version 2.1.4
  • git-svn version 2.11.0 (svn 1.9.5)

Initialize the repository

Run make init (just make for help)

Doing so will clone the repository for it's osgeo official GIT mirror and initialize the git-svn machinery.

If you do already have a postgis repository clone you might speed up this step by defining a POSTGIS_GIT_REF env variable, like this:

POSTGIS_GIT_REF=$EXISTING_REPO/.git/objects make init

Synchronize

Synchronizing manually (which may help setting up and storing user/password for https access and verifying ssh access) is done by runnning make sync

Web hook daemon

Make sure synchronization can happen in non-interactive mode. This usually means adding public key of the user running the syncronization daemon and configuring the username/password pair for pushing via https to Gogs. Running the syncrhonization manually once should help you getting there.

When non-interactive sync works, you can run the daemon with:

make start-daemon

The script will create an update pipe file, world writeable, and will read from it, synchronizing after 10 seconds of inactivity from last event read.

You'll probably want to setup a CGI script or similar to write an event line into that pipe whenever SVN repository is updated. An example such CGI script is update-mirrors.cgi (use with care!)