Create scratch git repos

* jeepyb/cmd/create_cgitrepos.py: Create empty git repositories
which shadow the publicized repository URLs but are in the form of
proto://host.example.org/subpath/orgname/project.git instead, where
"subpath" is configurable via a SCRATCH_SUBPATH environment
variable. If the variable is not supplied, no scratch projects will
be created and this change will be a no-op. Ownership of the
directories can be set similarly with SCRATCH_OWNER and
SCRATCH_GROUP.

This is intended to be used for arbitrary throwaway references such
as those created by openstack-infra/zuul. As such, it is not
included in the browsable cgit WebUI so as to avoid confusion. A
side effect of this is that any organization name which is the same
as the scratch subpath will cause the script to abort, ensuring
collisions between these do not occur.

Change-Id: Ie111b55dba18e2ecd8bd41394c097cbdc330db18
1 file changed