Add a localhost-only web console so VM and image management no longer depends on the CLI for every inspection and lifecycle action. Wire bangerd up to a configurable web listener, expose dashboard and async image-build state through the daemon, and serve CSRF-protected HTML pages with host-path picking, VM/image detail views, logs, ports, and progress polling for long-running operations. Keep the browser path aligned with the existing sudo and host-owned artifact model: surface sudo readiness, print the web URL in daemon status, and document the new workflow. Polish the UI with resource usage cards, clearer clickable affordances, cancel paths, confirmation prompts, image-name links, and HTTP port links. Validation: GOCACHE=/tmp/banger-gocache go test ./...
20 lines
952 B
HTML
20 lines
952 B
HTML
{{define "operation_content"}}
|
|
<section class="operation-card" data-operation-url="{{.OperationStatusURL}}" {{if .OperationSuccessURL}}data-operation-success="{{.OperationSuccessURL}}"{{end}}>
|
|
<h2>{{if eq .OperationKind "vm"}}VM readiness{{else}}Managed image build{{end}}</h2>
|
|
{{if .VMCreateOperation}}
|
|
<h3 id="operation-stage">{{.VMCreateOperation.Stage}}</h3>
|
|
<p id="operation-detail">{{.VMCreateOperation.Detail}}</p>
|
|
<p class="muted" id="operation-error">{{.VMCreateOperation.Error}}</p>
|
|
{{end}}
|
|
{{if .ImageBuildOperation}}
|
|
<h3 id="operation-stage">{{.ImageBuildOperation.Stage}}</h3>
|
|
<p id="operation-detail">{{.ImageBuildOperation.Detail}}</p>
|
|
<p class="muted" id="operation-error">{{.ImageBuildOperation.Error}}</p>
|
|
{{end}}
|
|
{{if .OperationLogPath}}
|
|
<p class="muted">Build log: <code id="operation-log">{{.OperationLogPath}}</code></p>
|
|
{{else}}
|
|
<p class="muted" id="operation-log"></p>
|
|
{{end}}
|
|
</section>
|
|
{{end}}
|