blob: 1ae4eb2c8603c6ab91a1f5cc2b34047d5142ff75 [file] [log] [blame]
<!doctype html>
<html>
<head>
<title>Vanadium {{title .ServerName}} Allocator</title>
{{template "head" .}}
</head>
<!-- NOTE: we 'borrow' a lot of the styling of identityd, hence the
security-related terminology in the style elements, like identity and
blessing. -->
<body class="identityprovider-layout">
{{template "header" .}}
<script>
function changeBtn(id, newHTML) {
document.getElementById(id).innerHTML = "<font color='gray'>"+newHTML+"</font>";
}
</script>
<main>
<h1 class="page-head">Create and Manage Instances of {{title .ServerName}}</h1>
<div class="blessings-list">
<div class="blessings-header">
<h1>Your instances</h1>
</div>
{{range $index, $element := .Instances}}
<div class="blessings-item">
<div class="blessing-details">
<h3>{{kubeName .Name}}</h3>
<p class="blessing-caveats unixtime" data-unixtime={{.CreationTime.Unix}}>
<b>Creation Time</b><br/>
{{.CreationTime.String}}
</p>
<p>
<b>Mount Name</b><br/>
<i>{{.NameRoot}}/</i><wbr/>{{relativeName .Name}}
</p>
<p class="blessing-caveats">
<b>Blessing Patterns</b><br/>
{{range .BlessingPatterns}}
{{.}}<br/>
{{end}}
</p>
</div>
<div class="blessing-revoked">
<a href="{{.DashboardURL}}" class="button-passive" target="_blank">Dashboard</a>
</div>
<div class="blessing-revoked" id="destroyBtn{{$index}}">
<a href="{{.DestroyURL}}" class="button-passive" onclick="changeBtn('destroyBtn{{$index}}', 'Destroying (takes a few seconds) ...')">Destroy</a>
</div>
</div>
{{else}}
None found.
{{end}}
<p>
<span id="createBtn"><a href="{{.CreateURL}}" class="button-passive" onclick="changeBtn('createBtn', 'Creating (takes a few seconds) ...')">Create New</a></span>
</p>
{{with .Message -}}
<hr>
<p>
<font size="2">{{.}}</font>
</p>
{{end}}
</font>
</main>
</body>
</html>