go.chromium.org/luci@v0.0.0-20240309015107-7cdc2e660f33/scheduler/appengine/frontend/templates/pages/job.html (about) 1 {{define "title"}}LUCI Scheduler :: {{.Job.ProjectID}} :: {{.Job.JobName}}{{end}} 2 3 {{define "head"}} 4 <style type="text/css"> 5 #invocations-table { 6 table-layout: fixed; 7 } 8 .underline { 9 text-decoration: underline !important; 10 } 11 12 #invocations-table td.long { 13 white-space: nowrap; 14 overflow: hidden; 15 text-overflow: ellipsis; 16 } 17 18 nav.top-pager ul.pager { 19 margin-top: 0px; 20 margin-bottom: 10px; 21 } 22 23 nav.bottom-pager ul.pager { 24 margin-top: 10px; 25 margin-bottom: 0px; 26 } 27 28 #paused-alert { 29 margin-top: 10px; 30 margin-bottom: 5px; 31 } 32 33 .small-hr { 34 margin-top: 10px; 35 margin-bottom: 10px; 36 } 37 </style> 38 {{end}} 39 40 41 {{define "invocations-list"}} 42 {{range .Second }} 43 <tr class="{{.RowClass}}"> 44 <td><a href="/jobs/{{$.First.ProjectID}}/{{$.First.JobName}}/{{.InvID}}">{{.InvID}}</a></td> 45 <td>{{.Started}}</td> 46 <td class="long" title="{{.TriggeredBy}}">{{.TriggeredBy}}</td> 47 <td>{{.Duration}}</td> 48 <td> 49 {{if .ViewURL}} 50 <a href="{{.ViewURL}}" target="_blank" class="underline label {{.LabelClass}}">{{.Status}}</a> 51 {{else}} 52 <span class="label {{.LabelClass}}">{{.Status}}</span> 53 {{end}} 54 </td> 55 </tr> 56 {{end}} 57 {{end}} 58 59 60 {{define "pager"}} 61 <ul class="pager"> 62 {{if .PrevCursor}} 63 <li class="previous"> 64 {{if eq .PrevCursor "NULL"}} 65 <a href="/jobs/{{$.Job.ProjectID}}/{{$.Job.JobName}}"> 66 {{else}} 67 <a href="/jobs/{{$.Job.ProjectID}}/{{$.Job.JobName}}?c={{.PrevCursor}}"> 68 {{end}} 69 <span aria-hidden="true">←</span> Newer 70 </a> 71 </li> 72 {{else}} 73 <li class="previous disabled"> 74 <a href="#"><span aria-hidden="true">←</span> Newer</a> 75 </li> 76 {{end}} 77 {{if .NextCursor}} 78 <li class="next"> 79 <a href="/jobs/{{$.Job.ProjectID}}/{{$.Job.JobName}}?c={{.NextCursor}}"> 80 Older <span aria-hidden="true">→</span> 81 </a> 82 </li> 83 {{else}} 84 <li class="next disabled"> 85 <a href="#">Older <span aria-hidden="true">→</span></a> 86 </li> 87 {{end}} 88 </ul> 89 {{end}} 90 91 92 {{define "content"}} 93 94 <ol class="breadcrumb"> 95 <li class="breadcrumb-item"><a href="/">All projects</a></li> 96 <li class="breadcrumb-item"><a href="/jobs/{{.Job.ProjectID}}">{{.Job.ProjectID}}</a></li> 97 <li class="breadcrumb-item active">{{template "job-id-static" .Job}}</li> 98 </ol> 99 100 <div class="row"> 101 <div class="col-sm-3"><b>State:</b> 102 <span class="label {{.Job.LabelClass}}">{{.Job.State}}</span> 103 </div> 104 <div class="col-sm-3"><b>Schedule:</b> {{.Job.Schedule}}</div> 105 <div class="col-sm-3"><b>Next run:</b> {{.Job.NextRun}}</div> 106 <div class="col-sm-3"><b>Actions:</b>{{template "job-action-buttons" .Job}}</div> 107 </div> 108 109 {{if .Job.Paused}} 110 <div class="row"> 111 <div class="col-sm-12"> 112 <div class="alert alert-warning" role="alert" id="paused-alert"> 113 <b>Paused by {{.Job.PausedBy}} {{.Job.PausedWhen}}:</b> {{.Job.PausedReason}} 114 </div> 115 </div> 116 </div> 117 {{end}} 118 119 <div class="row"> 120 <div class="col-sm-12"> 121 <hr class="small-hr"> 122 </div> 123 </div> 124 125 {{if .ShowJobHeader}} 126 127 <h4>Definition 128 {{if .Job.RevisionURL}} 129 (rev <a href="{{.Job.RevisionURL}}" target="_blank">{{.Job.Revision}}</a>) 130 {{else}} 131 (rev {{.Job.Revision}}) 132 {{end}} 133 </h4> 134 <div class="row"> 135 <div class="col-sm-6"> 136 <h5>Task</h5> 137 <pre>{{.Job.Definition}}</pre> 138 </div> 139 <div class="col-sm-6"> 140 <h5>Triggering policy</h5> 141 <pre>{{.Job.Policy}}</pre> 142 </div> 143 </div> 144 145 {{if .Job.TriageLog.Available}} 146 <div class="row"> 147 <div class="col-sm-12"> 148 <h5>Last triage ({{.Job.TriageLog.LastTriage}})</h5> 149 {{if .Job.TriageLog.Stale}} 150 <div class="alert alert-danger" role="alert"> 151 This log is stale! The log is {{.Job.TriageLog.Staleness}} older than 152 the expected. Please investigate GAE logs to see why the triage log is 153 not being updated. 154 </div> 155 {{end}} 156 <pre>{{.Job.TriageLog.DebugLog}}</pre> 157 </div> 158 </div> 159 {{end}} 160 161 {{if .PendingTriggers}} 162 <h4>Pending triggers</h4> 163 <div class="row"> 164 <div class="col-sm-12"> 165 {{template "triggers-list" .PendingTriggers}} 166 </div> 167 </div> 168 {{end}} 169 170 <div class="row"> 171 <div class="col-sm-12"> 172 <hr class="small-hr"> 173 </div> 174 </div> 175 176 {{end}} 177 178 <div class="row"> 179 <div class="col-sm-12"> 180 <nav class="top-pager">{{template "pager" .}}</nav> 181 <table class="table table-condensed" id="invocations-table"> 182 <thead> 183 <tr> 184 <th class="col-lg-2">ID</th> 185 <th class="col-lg-2">Started</th> 186 <th class="col-lg-3">Triggered by</th> 187 <th class="col-lg-2">Duration</th> 188 <th class="col-lg-2">Status</th> 189 </tr> 190 </thead> 191 <tbody> 192 {{if .InvocationsActive}} 193 {{template "invocations-list" Pair .Job .InvocationsActive}} 194 <tr> 195 <td colspan="5"> 196 <hr style="margin-top: 2px; margin-bottom: 2px;"/> 197 </td> 198 </tr> 199 {{end}} 200 {{template "invocations-list" Pair .Job .InvocationsLog}} 201 </tbody> 202 </table> 203 <nav class="bottom-pager">{{template "pager" .}}</nav> 204 </div> 205 </div> 206 207 {{end}}