We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4d8a2a3 commit 8aa0116Copy full SHA for 8aa0116
apps/dokploy/pages/api/deploy/[refreshToken].ts
@@ -319,8 +319,17 @@ export function extractImageTag(dockerImage: string | null) {
319
return null;
320
}
321
322
- const tag = dockerImage.split(":").pop();
323
- return tag === dockerImage ? "latest" : tag;
+ const lastColonIndex = dockerImage.lastIndexOf(":");
+ if (lastColonIndex === -1) {
324
+ return "latest";
325
+ }
326
+
327
+ const afterColon = dockerImage.substring(lastColonIndex + 1);
328
+ if (/^\d{1,5}$/.test(afterColon)) {
329
330
331
332
+ return afterColon;
333
334
335
/**
0 commit comments