* .../nodepool/scripts/cache_git_repos.py: Since the projects list
is not being retrieved as part of a git repository, use HTTPS
protocol rather than HTTP so it will be consistent with the way we
retrieve the bootstrap script in prepare_node.sh.
* .../nodepool/scripts/prepare_node.sh: Switch the config clone
operation from the Gerrit server to the Git server farm, since the
former does not support git protocol. Also make it a shallow clone
since we just need the files.
Change-Id: I1dc0697bb3f9832d180b6b1ebffaa563bd886281
Previously, nodepool's prep scripts would not abort when
encountering git cloning errors. Now we retry once on failure and
then abort if it fails a second time. Also the script now makes sure
the clone actually results in a functional copy of each repository
by attempting to list branches and reset to HEAD.
Change-Id: I84565e4e90b34c6a9b8c86754efdde137cda08b2
For performance reasons--using git protocol instead of HTTP should
speed up cloning significantly on CentOS 6 in particular.
Change-Id: I37fadb1366eab5d66ec8e95945bea9c2c0251fcb
Strictly speaking, we only need sync calls at the end of the
script that is directly invoked by nodepool. But just so we
don't have to think about it too much, add them to all prepare
scripts.
Without it, clouds will happily snapshot a system without all
the data written to disk!
Closes-Bug: 1282136
Change-Id: Id7dcf6667d6e48eb5ae95fd42b09f0651eeb38f9
The projects list is a common list for devs to interact with. The config
in the list is not, but the config in the list means the file needs to
be in an erb template.
Split the two concerns, similar to zuul. Put the config in a config file
and the project data in a yaml file.
Change-Id: I708b8655b4b1ce377f3b7369e987418c1d72d977
Cache all review.openstack.org git repos in /opt/git.
Subsequent changes to gerrit-git-prep and devstack-gate will make
use of these repos (eventually deprecating the devstack-gate repos
is ~jenkins/workspace-cache).
Refactor the devstack cache python script a bit to make common
functions reusable. Also rename it because underscores are better
than hyphens for python file names.
Change-Id: I4ae40613ebcca62b0dfc2eaba159557a4c71a529