Add a load of fallbacks and rework the docker bits
All checks were successful
Build and deploy / deploy (push) Successful in 1m58s
All checks were successful
Build and deploy / deploy (push) Successful in 1m58s
This commit is contained in:
@@ -16,45 +16,34 @@ export default async function Home() {
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
<th>Image</th>
|
||||
<th>Version</th>
|
||||
<th>Tag</th>
|
||||
<th>Short Hash</th>
|
||||
<th>Version</th>
|
||||
<th>Tag</th>
|
||||
<th>Short Hash</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{list
|
||||
.sort((ca, cb) => {
|
||||
if (ca.Names[0] && cb.Names[0]) {
|
||||
if (ca.Names[0] < cb.Names[0]) {
|
||||
if (ca.containerName && cb.containerName) {
|
||||
if (ca.containerName < cb.containerName) {
|
||||
return -1;
|
||||
}
|
||||
if (ca.Names[0] > cb.Names[0]) {
|
||||
if (ca.containerName > cb.containerName) {
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
})
|
||||
.map((containerInfo) => {
|
||||
const outdated =
|
||||
containerInfo.current.version !==
|
||||
containerInfo.latest.version ||
|
||||
containerInfo.current.hash !==
|
||||
containerInfo.latest.hash;
|
||||
const outdated = containerInfo.current.hash !== containerInfo.latest.hash;
|
||||
return (
|
||||
<tr
|
||||
key={containerInfo.Image.split(":")[0]}
|
||||
className={`${outdated ? "bg-base-200" : null}`}
|
||||
>
|
||||
<td
|
||||
className={`border-l-8 ${outdated ? "border-l-error/80" : "border-l-info/80"}`}
|
||||
>
|
||||
{containerInfo.Names[0]?.substring(1)}
|
||||
</td>
|
||||
<td>{containerInfo.Image.split(":")[0]}</td>
|
||||
<td>{containerInfo.current.version}</td>
|
||||
<tr key={containerInfo.containerName} className={`${outdated ? "bg-base-200" : null}`}>
|
||||
<td className={`border-l-8 ${outdated ? "border-l-error/80" : "border-l-info/80"}`}>{containerInfo.containerName}</td>
|
||||
<td>{containerInfo.imageName}</td>
|
||||
<td>{containerInfo.current.tag}</td>
|
||||
<td>{containerInfo.current.hash}</td>
|
||||
<td>{containerInfo.latest.version}</td>
|
||||
<td>{containerInfo.latest.tag}</td>
|
||||
<td>{containerInfo.latest.hash}</td>
|
||||
</tr>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user