mirror of
https://github.com/Dokploy/templates
synced 2025-06-26 18:16:07 +00:00
feat: migrate templates
This commit is contained in:
@@ -1,26 +0,0 @@
|
||||
import {
|
||||
type DomainSchema,
|
||||
type Schema,
|
||||
type Template,
|
||||
generateBase64,
|
||||
generateRandomDomain,
|
||||
} from "../utils";
|
||||
|
||||
export function generate(schema: Schema): Template {
|
||||
const mainDomain = generateRandomDomain(schema);
|
||||
const masterKey = generateBase64(32);
|
||||
|
||||
const domains: DomainSchema[] = [
|
||||
{
|
||||
host: mainDomain,
|
||||
port: 7700,
|
||||
serviceName: "meilisearch",
|
||||
},
|
||||
];
|
||||
const envs = ["MEILI_ENV=development", `MEILI_MASTER_KEY=${masterKey}`];
|
||||
|
||||
return {
|
||||
envs,
|
||||
domains,
|
||||
};
|
||||
}
|
||||
15
blueprints/meilisearch/template.yml
Normal file
15
blueprints/meilisearch/template.yml
Normal file
@@ -0,0 +1,15 @@
|
||||
variables:
|
||||
main_domain: ${randomDomain}
|
||||
master_key: ${generateBase64(32)}
|
||||
|
||||
config:
|
||||
domains:
|
||||
- serviceName: meilisearch
|
||||
port: 7700
|
||||
host: ${main_domain}
|
||||
|
||||
env:
|
||||
MEILI_ENV: "development"
|
||||
MEILI_MASTER_KEY: ${master_key}
|
||||
|
||||
mounts: []
|
||||
Reference in New Issue
Block a user