mirror of
https://github.com/andwati/dokploy.git
synced 2026-10-27 15:32:16 +00:00
feat: added restart button for containers
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { z } from "zod";
|
||||
import {
|
||||
getConfig,
|
||||
containerRestart,
|
||||
getContainers,
|
||||
getContainersByAppLabel,
|
||||
getContainersByAppNameMatch,
|
||||
@@ -12,6 +13,15 @@ export const dockerRouter = createTRPCRouter({
|
||||
return await getContainers();
|
||||
}),
|
||||
|
||||
restartContainer: protectedProcedure
|
||||
.input(
|
||||
z.object({
|
||||
containerId: z.string().min(1),
|
||||
}),
|
||||
).mutation(async ({ input }) => {
|
||||
return await containerRestart(input.containerId);
|
||||
}),
|
||||
|
||||
getConfig: protectedProcedure
|
||||
.input(
|
||||
z.object({
|
||||
|
||||
Reference in New Issue
Block a user