mirror of
https://github.com/andwati/dokploy.git
synced 2026-11-22 03:48:46 +00:00
refactor(gitlab): reorder token refresh and provider fetching for improved clarity
This commit is contained in:
@@ -371,9 +371,9 @@ export const cloneRawGitlabRepository = async (entity: Compose) => {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
const gitlabProvider = await findGitlabById(gitlabId);
|
|
||||||
const { COMPOSE_PATH } = paths();
|
const { COMPOSE_PATH } = paths();
|
||||||
await refreshGitlabToken(gitlabId);
|
await refreshGitlabToken(gitlabId);
|
||||||
|
const gitlabProvider = await findGitlabById(gitlabId);
|
||||||
const basePath = COMPOSE_PATH;
|
const basePath = COMPOSE_PATH;
|
||||||
const outputPath = join(basePath, appName, "code");
|
const outputPath = join(basePath, appName, "code");
|
||||||
await recreateDirectory(outputPath);
|
await recreateDirectory(outputPath);
|
||||||
@@ -419,9 +419,9 @@ export const cloneRawGitlabRepositoryRemote = async (compose: Compose) => {
|
|||||||
message: "Gitlab Provider not found",
|
message: "Gitlab Provider not found",
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
const gitlabProvider = await findGitlabById(gitlabId);
|
|
||||||
const { COMPOSE_PATH } = paths(true);
|
const { COMPOSE_PATH } = paths(true);
|
||||||
await refreshGitlabToken(gitlabId);
|
await refreshGitlabToken(gitlabId);
|
||||||
|
const gitlabProvider = await findGitlabById(gitlabId);
|
||||||
const basePath = COMPOSE_PATH;
|
const basePath = COMPOSE_PATH;
|
||||||
const outputPath = join(basePath, appName, "code");
|
const outputPath = join(basePath, appName, "code");
|
||||||
const repoClone = getGitlabRepoClone(gitlabProvider, gitlabPathNamespace);
|
const repoClone = getGitlabRepoClone(gitlabProvider, gitlabPathNamespace);
|
||||||
|
|||||||
Reference in New Issue
Block a user