mirror of
https://github.com/Dokploy/templates
synced 2025-06-26 18:16:07 +00:00
feat: Add numerous new blueprint templates for various applications
This commit is contained in:
36
blueprints/maybe/docker-compose.yml
Normal file
36
blueprints/maybe/docker-compose.yml
Normal file
@@ -0,0 +1,36 @@
|
||||
services:
|
||||
app:
|
||||
image: ghcr.io/maybe-finance/maybe:sha-68c570eed8810fd59b5b33cca51bbad5eabb4cb4
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- ../files/uploads:/app/uploads
|
||||
environment:
|
||||
DATABASE_URL: postgresql://maybe:maybe@db:5432/maybe
|
||||
SECRET_KEY_BASE: ${SECRET_KEY_BASE}
|
||||
SELF_HOSTED: true
|
||||
SYNTH_API_KEY: ${SYNTH_API_KEY}
|
||||
RAILS_FORCE_SSL: "false"
|
||||
RAILS_ASSUME_SSL: "false"
|
||||
GOOD_JOB_EXECUTION_MODE: async
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_healthy
|
||||
|
||||
db:
|
||||
image: postgres:16
|
||||
restart: always
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
volumes:
|
||||
- db-data:/var/lib/postgresql/data
|
||||
environment:
|
||||
POSTGRES_DB: maybe
|
||||
POSTGRES_USER: maybe
|
||||
POSTGRES_PASSWORD: maybe
|
||||
|
||||
volumes:
|
||||
db-data:
|
||||
43
blueprints/maybe/index.ts
Normal file
43
blueprints/maybe/index.ts
Normal file
@@ -0,0 +1,43 @@
|
||||
import {
|
||||
type DomainSchema,
|
||||
type Schema,
|
||||
type Template,
|
||||
generateBase64,
|
||||
generateRandomDomain,
|
||||
} from "../utils";
|
||||
|
||||
export function generate(schema: Schema): Template {
|
||||
const mainDomain = generateRandomDomain(schema);
|
||||
const secretKeyBase = generateBase64(64);
|
||||
const synthApiKey = generateBase64(32);
|
||||
|
||||
const domains: DomainSchema[] = [
|
||||
{
|
||||
host: mainDomain,
|
||||
port: 3000,
|
||||
serviceName: "app",
|
||||
},
|
||||
];
|
||||
|
||||
const envs = [
|
||||
`SECRET_KEY_BASE=${secretKeyBase}`,
|
||||
"SELF_HOSTED=true",
|
||||
`SYNTH_API_KEY=${synthApiKey}`,
|
||||
"RAILS_FORCE_SSL=false",
|
||||
"RAILS_ASSUME_SSL=false",
|
||||
"GOOD_JOB_EXECUTION_MODE=async",
|
||||
];
|
||||
|
||||
const mounts: Template["mounts"] = [
|
||||
{
|
||||
filePath: "./uploads",
|
||||
content: "This is where user uploads will be stored",
|
||||
},
|
||||
];
|
||||
|
||||
return {
|
||||
envs,
|
||||
mounts,
|
||||
domains,
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user