mirror of
https://github.com/Dokploy/dokploy
synced 2025-06-26 18:27:59 +00:00
25 lines
518 B
TypeScript
25 lines
518 B
TypeScript
import {
|
|
generateHash,
|
|
generateRandomDomain,
|
|
type Template,
|
|
type Schema,
|
|
generateBase64,
|
|
} from "../utils";
|
|
|
|
export function generate(schema: Schema): Template {
|
|
const mainServiceHash = generateHash(schema.projectName);
|
|
const randomDomain = generateRandomDomain(schema);
|
|
const masterKey = generateBase64(32);
|
|
const envs = [
|
|
`MEILISEARCH_HOST=${randomDomain}`,
|
|
"MEILISEARCH_PORT=7700",
|
|
"MEILI_ENV=development",
|
|
`MEILI_MASTER_KEY=${masterKey}`,
|
|
`HASH=${mainServiceHash}`,
|
|
];
|
|
|
|
return {
|
|
envs,
|
|
};
|
|
}
|