[Verify] Add 'version' arg to install/reinstall cmd
For now Rally always installs Tempest from the master branch. It is not very convenient because Tempest may be broken in the master branch and it would be very useful to use some commit or tag for Tempest. So this commit adds a possibility to checkout the specified commit or tag before Tempest installation. Change-Id: Icfbb4221005466139c14d3f4aae34bbb3e013982
This commit is contained in:
parent
d4185281ac
commit
3832199890
@ -50,9 +50,9 @@ _rally()
|
||||
OPTS["verify_discover"]="--deployment --pattern"
|
||||
OPTS["verify_genconfig"]="--deployment --tempest-config --override"
|
||||
OPTS["verify_import"]="--deployment --set --file --no-use"
|
||||
OPTS["verify_install"]="--deployment --source --system-wide"
|
||||
OPTS["verify_install"]="--deployment --source --version --system-wide"
|
||||
OPTS["verify_list"]=""
|
||||
OPTS["verify_reinstall"]="--deployment --source --system-wide"
|
||||
OPTS["verify_reinstall"]="--deployment --source --version --system-wide"
|
||||
OPTS["verify_results"]="--uuid --html --json --output-file"
|
||||
OPTS["verify_show"]="--uuid --sort-by --detailed"
|
||||
OPTS["verify_showconfig"]="--deployment"
|
||||
|
@ -171,8 +171,22 @@ def main():
|
||||
|
||||
render_vars = {"verifications": []}
|
||||
|
||||
# Verification management stuff
|
||||
# Install Tempest
|
||||
render_vars["install"] = call_rally("verify install")
|
||||
|
||||
# Get Rally deployment ID
|
||||
rally_deployment_id = subprocess.check_output(
|
||||
"rally deployment list | awk '/devstack/ {print $2}'",
|
||||
shell=True, stderr=subprocess.STDOUT)
|
||||
# Get the penultimate Tempest commit ID
|
||||
tempest_commit_id = subprocess.check_output(
|
||||
"cd /home/jenkins/.rally/tempest/for-deployment-%s "
|
||||
"git log --skip 1 -n 1 | awk '/commit/ {print $2}' | head -1"
|
||||
% rally_deployment_id, shell=True, stderr=subprocess.STDOUT).strip()
|
||||
# Reinstall Tempest with providing the --version arg to the command
|
||||
render_vars["reinstall"] = call_rally(
|
||||
"verify reinstall --version %s" % tempest_commit_id)
|
||||
|
||||
render_vars["genconfig"] = call_rally("verify genconfig")
|
||||
render_vars["showconfig"] = call_rally("verify showconfig")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user