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:
37
blueprints/coder/docker-compose.yml
Normal file
37
blueprints/coder/docker-compose.yml
Normal file
@@ -0,0 +1,37 @@
|
||||
services:
|
||||
coder:
|
||||
image: ghcr.io/coder/coder:v2.15.3
|
||||
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
group_add:
|
||||
- "998"
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_healthy
|
||||
environment:
|
||||
- CODER_ACCESS_URL
|
||||
- CODER_HTTP_ADDRESS
|
||||
- CODER_PG_CONNECTION_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@db/${POSTGRES_DB}?sslmode=disable
|
||||
|
||||
db:
|
||||
image: postgres:17
|
||||
|
||||
environment:
|
||||
- POSTGRES_PASSWORD
|
||||
- POSTGRES_USER
|
||||
- POSTGRES_DB
|
||||
healthcheck:
|
||||
test:
|
||||
[
|
||||
"CMD-SHELL",
|
||||
"pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}",
|
||||
]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
volumes:
|
||||
- db_coder_data:/var/lib/postgresql/data
|
||||
|
||||
volumes:
|
||||
db_coder_data:
|
||||
30
blueprints/coder/index.ts
Normal file
30
blueprints/coder/index.ts
Normal file
@@ -0,0 +1,30 @@
|
||||
import {
|
||||
type DomainSchema,
|
||||
type Schema,
|
||||
type Template,
|
||||
generateRandomDomain,
|
||||
} from "../utils";
|
||||
|
||||
export function generate(schema: Schema): Template {
|
||||
const domains: DomainSchema[] = [
|
||||
{
|
||||
host: generateRandomDomain(schema),
|
||||
port: 7080,
|
||||
serviceName: "coder",
|
||||
},
|
||||
];
|
||||
|
||||
const envs = [
|
||||
"CODER_ACCESS_URL=",
|
||||
"CODER_HTTP_ADDRESS=0.0.0.0:7080",
|
||||
"",
|
||||
"POSTGRES_DB=coder",
|
||||
"POSTGRES_USER=coder",
|
||||
"POSTGRES_PASSWORD=VERY_STRONG_PASSWORD",
|
||||
];
|
||||
|
||||
return {
|
||||
domains,
|
||||
envs,
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user