From ae8bb5fc134ac4ab354489b30e814536fcf9f2e0 Mon Sep 17 00:00:00 2001 From: Joseph Schorr Date: Thu, 12 Feb 2015 16:38:43 -0500 Subject: [PATCH] Add preparing build node status item and change the build status colors to be variations on a blue color --- buildman/server.py | 4 ++++ static/css/quay.css | 22 +++++++++------------- static/js/app.js | 3 +++ 3 files changed, 16 insertions(+), 13 deletions(-) diff --git a/buildman/server.py b/buildman/server.py index 7b10995b4..ebbc558bb 100644 --- a/buildman/server.py +++ b/buildman/server.py @@ -11,6 +11,7 @@ from threading import Event from trollius.coroutines import From from datetime import timedelta +from buildman.jobutil.buildstatus import StatusHandler from buildman.jobutil.buildjob import BuildJob, BuildJobLoadException from data import database from data.queue import WorkQueue @@ -158,6 +159,9 @@ class BuilderServer(object): logger.debug('Build job found. Checking for an avaliable worker.') scheduled = yield From(self._lifecycle_manager.schedule(build_job)) if scheduled: + status_handler = StatusHandler(self._build_logs, build_job.repo_build.uuid) + status_handler.set_phase('build-scheduled') + self._job_count = self._job_count + 1 logger.debug('Build job scheduled. Running: %s', self._job_count) else: diff --git a/static/css/quay.css b/static/css/quay.css index 9046bf722..e09fce346 100644 --- a/static/css/quay.css +++ b/static/css/quay.css @@ -845,28 +845,24 @@ i.toggle-icon:hover { background-color: #DFFF00; } -.phase-icon.waiting, .phase-icon.unpacking, .phase-icon.starting, .phase-icon.initializing { - background-color: #ddd; +.phase-icon.waiting, .phase-icon.build-scheduled { + background-color: rgba(66, 139, 202, 0.2); } -.phase-icon.pulling { - background-color: #cab442; +.phase-icon.unpacking, .phase-icon.starting, .phase-icon.initializing { + background-color: rgba(66, 139, 202, 0.4); } -.phase-icon.building { - background-color: #f0ad4e; +.phase-icon.pulling, .phase-icon.priming-cache, .phase-icon.checking-cache { + background-color: rgba(66, 139, 202, 0.6); } -.phase-icon.priming-cache, .phase-icon.checking-cache { - background-color: #cab442; -} - -.phase-icon.pushing { - background-color: #5cb85c; +.phase-icon.pushing, .phase-icon.building { + background-color: rgba(66, 139, 202, 0.8); } .phase-icon.complete { - background-color: #428bca; + background-color: rgba(66, 139, 202, 1); } .build-status { diff --git a/static/js/app.js b/static/js/app.js index ed9c7a842..63f697755 100644 --- a/static/js/app.js +++ b/static/js/app.js @@ -5830,6 +5830,9 @@ quayApp.directive('buildMessage', function () { case 'priming-cache': return 'Priming cache for build'; + case 'build-scheduled': + return 'Preparing build node'; + case 'pushing': return 'Pushing image built from Dockerfile';