| 1 | {{define "account_fleet"}}{{template "top" .}} |
| 2 | {{if .Flash}}<p class="banner">{{.Flash}}</p>{{end}} |
| 3 | {{if .FlashErr}}<p class="banner error">{{.FlashErr}}</p>{{end}} |
| 4 | <div class="pagehead"> |
| 5 | <p class="eyebrow">Fleet · {{.Account.Name}}</p> |
| 6 | <h1>Fleet</h1> |
| 7 | <p class="lede">Where this account's apps run — the shared fleet, and boxes you bring.</p> |
| 8 | </div> |
| 9 | |
| 10 | <h2>{{.SharedFleet.Title}} |
| 11 | {{if .SharedFleet.PlacementKnown}}{{if .SharedFleet.Active}}<span class="chip chip-env">Active</span> |
| 12 | {{else}}<span class="chip chip-env">Not used</span>{{end}}{{end}}</h2> |
| 13 | {{if .SharedFleet.Boxes}} |
| 14 | <p>{{.SharedFleet.Boxes}} box{{if ne .SharedFleet.Boxes 1}}es{{end}}{{if .SharedFleet.Regions}} in |
| 15 | {{range .SharedFleet.Regions}}<span class="chip chip-env">{{.}}</span> {{end}}{{end}}</p> |
| 16 | {{else}}<p class="small">No shared boxes are reporting right now.</p>{{end}} |
| 17 | {{if .SharedFleet.PlacementKnown}} |
| 18 | <p class="small">{{if .SharedFleet.Active}}{{.SharedFleet.PlatformApps}} of your apps |
| 19 | {{if eq .SharedFleet.PlatformApps 1}}runs{{else}}run{{end}} here. Apps run on the shared fleet |
| 20 | unless you place them on a fleet of your own.{{else}}None of your apps run on the shared |
| 21 | fleet.{{end}}</p> |
| 22 | {{else}}<p class="small">Whether your apps run here could not be read just now.</p>{{end}} |
| 23 | |
| 24 | <h2>Your fleets</h2> |
| 25 | {{if .AccountFleets}} |
| 26 | <div class="tablewrap"> |
| 27 | <table> |
| 28 | <tr><th>Fleet</th><th>Boxes</th><th>Reachable</th><th>Placed apps</th></tr> |
| 29 | {{range .AccountFleets}} |
| 30 | <tr> |
| 31 | <td><a href="{{$.Nav}}/fleets/{{.Name}}">{{.Name}}</a></td> |
| 32 | <td>{{.Boxes}}</td> |
| 33 | <td>{{.Reachable}}</td> |
| 34 | <td>{{.Apps}}</td> |
| 35 | </tr> |
| 36 | {{end}} |
| 37 | </table> |
| 38 | </div> |
| 39 | {{else if .FleetsKnown}}<p class="small">No fleets of your own yet.</p> |
| 40 | {{else}}<p class="small">Your fleets could not be read just now.</p>{{end}} |
| 41 | |
| 42 | <h2>Bring your own fleet</h2> |
| 43 | <p>Run your apps on hardware you own — an office box, a Raspberry Pi, your own cloud account. |
| 44 | Your boxes dial out to the platform; nothing connects in.</p> |
| 45 | <p><a class="btn" href="{{.Nav}}/fleet/byo">How to add and harden a box</a></p> |
| 46 | {{template "bottom" .}}{{end}} |
| 47 | |