mirror of
https://github.com/Dokploy/dokploy
synced 2025-06-26 18:27:59 +00:00
refactor: update lint
This commit is contained in:
@@ -37,13 +37,13 @@ export type ApplicationNested = InferResultType<
|
|||||||
|
|
||||||
export const buildApplication = async (
|
export const buildApplication = async (
|
||||||
application: ApplicationNested,
|
application: ApplicationNested,
|
||||||
logPath: string
|
logPath: string,
|
||||||
) => {
|
) => {
|
||||||
const writeStream = createWriteStream(logPath, { flags: "a" });
|
const writeStream = createWriteStream(logPath, { flags: "a" });
|
||||||
const { buildType, sourceType } = application;
|
const { buildType, sourceType } = application;
|
||||||
try {
|
try {
|
||||||
writeStream.write(
|
writeStream.write(
|
||||||
`\nBuild ${buildType}: ✅\nSource Type: ${sourceType}: ✅\n`
|
`\nBuild ${buildType}: ✅\nSource Type: ${sourceType}: ✅\n`,
|
||||||
);
|
);
|
||||||
console.log(`Build ${buildType}: ✅`);
|
console.log(`Build ${buildType}: ✅`);
|
||||||
if (buildType === "nixpacks") {
|
if (buildType === "nixpacks") {
|
||||||
@@ -77,7 +77,7 @@ export const buildApplication = async (
|
|||||||
|
|
||||||
export const getBuildCommand = (
|
export const getBuildCommand = (
|
||||||
application: ApplicationNested,
|
application: ApplicationNested,
|
||||||
logPath: string
|
logPath: string,
|
||||||
) => {
|
) => {
|
||||||
let command = "";
|
let command = "";
|
||||||
const { buildType, registry } = application;
|
const { buildType, registry } = application;
|
||||||
@@ -106,7 +106,7 @@ export const getBuildCommand = (
|
|||||||
};
|
};
|
||||||
|
|
||||||
export const mechanizeDockerContainer = async (
|
export const mechanizeDockerContainer = async (
|
||||||
application: ApplicationNested
|
application: ApplicationNested,
|
||||||
) => {
|
) => {
|
||||||
const {
|
const {
|
||||||
appName,
|
appName,
|
||||||
@@ -144,7 +144,7 @@ export const mechanizeDockerContainer = async (
|
|||||||
const filesMount = generateFileMounts(appName, application);
|
const filesMount = generateFileMounts(appName, application);
|
||||||
const envVariables = prepareEnvironmentVariables(
|
const envVariables = prepareEnvironmentVariables(
|
||||||
env,
|
env,
|
||||||
application.project.env
|
application.project.env,
|
||||||
);
|
);
|
||||||
|
|
||||||
const image = getImageName(application);
|
const image = getImageName(application);
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import { spawnAsync } from "../process/spawnAsync";
|
|||||||
|
|
||||||
export const uploadImage = async (
|
export const uploadImage = async (
|
||||||
application: ApplicationNested,
|
application: ApplicationNested,
|
||||||
writeStream: WriteStream
|
writeStream: WriteStream,
|
||||||
) => {
|
) => {
|
||||||
const registry = application.registry;
|
const registry = application.registry;
|
||||||
|
|
||||||
@@ -25,7 +25,7 @@ export const uploadImage = async (
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
writeStream.write(
|
writeStream.write(
|
||||||
`📦 [Enabled Registry] Uploading image to ${registry.registryType} | ${imageName} | ${finalURL}\n`
|
`📦 [Enabled Registry] Uploading image to ${registry.registryType} | ${imageName} | ${finalURL}\n`,
|
||||||
);
|
);
|
||||||
const loginCommand = spawnAsync(
|
const loginCommand = spawnAsync(
|
||||||
"docker",
|
"docker",
|
||||||
@@ -34,7 +34,7 @@ export const uploadImage = async (
|
|||||||
if (writeStream.writable) {
|
if (writeStream.writable) {
|
||||||
writeStream.write(data);
|
writeStream.write(data);
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
);
|
);
|
||||||
loginCommand.child?.stdin?.write(registry.password);
|
loginCommand.child?.stdin?.write(registry.password);
|
||||||
loginCommand.child?.stdin?.end();
|
loginCommand.child?.stdin?.end();
|
||||||
@@ -59,7 +59,7 @@ export const uploadImage = async (
|
|||||||
|
|
||||||
export const uploadImageRemoteCommand = (
|
export const uploadImageRemoteCommand = (
|
||||||
application: ApplicationNested,
|
application: ApplicationNested,
|
||||||
logPath: string
|
logPath: string,
|
||||||
) => {
|
) => {
|
||||||
const registry = application.registry;
|
const registry = application.registry;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user