mirror of
https://github.com/Dokploy/dokploy
synced 2025-06-26 18:27:59 +00:00
Add: Redis Password to AP
This commit is contained in:
@@ -19,7 +19,9 @@ services:
|
|||||||
- AP_POSTGRES_PORT=5432
|
- AP_POSTGRES_PORT=5432
|
||||||
- AP_REDIS_HOST=redis
|
- AP_REDIS_HOST=redis
|
||||||
- AP_REDIS_PORT=6379
|
- AP_REDIS_PORT=6379
|
||||||
|
- AP_REDIS_URL=redis://:${REDIS_PASSWORD}@redis:6379
|
||||||
- AP_ENVIRONMENT=prod
|
- AP_ENVIRONMENT=prod
|
||||||
|
- AP_FRONTEND_URL=https://${AP_HOST}
|
||||||
- AP_ENCRYPTION_KEY=${AP_ENCRYPTION_KEY}
|
- AP_ENCRYPTION_KEY=${AP_ENCRYPTION_KEY}
|
||||||
- AP_JWT_SECRET=${AP_JWT_SECRET}
|
- AP_JWT_SECRET=${AP_JWT_SECRET}
|
||||||
- AP_ENGINE_EXECUTABLE_PATH=dist/packages/engine/main.js
|
- AP_ENGINE_EXECUTABLE_PATH=dist/packages/engine/main.js
|
||||||
@@ -49,13 +51,13 @@ services:
|
|||||||
|
|
||||||
redis:
|
redis:
|
||||||
image: redis:7.0.7
|
image: redis:7.0.7
|
||||||
restart: unless-stopped
|
command: redis-server --requirepass ${REDIS_PASSWORD}
|
||||||
networks:
|
networks:
|
||||||
- dokploy-network
|
- dokploy-network
|
||||||
volumes:
|
volumes:
|
||||||
- redis_data:/data
|
- redis_data:/data
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "redis-cli", "ping"]
|
test: ["CMD", "redis-cli", "-a", "${REDIS_PASSWORD}", "ping"]
|
||||||
interval: 10s
|
interval: 10s
|
||||||
timeout: 5s
|
timeout: 5s
|
||||||
retries: 5
|
retries: 5
|
||||||
|
|||||||
@@ -9,11 +9,11 @@ import {
|
|||||||
export function generate(schema: Schema): Template {
|
export function generate(schema: Schema): Template {
|
||||||
const mainDomain = generateRandomDomain(schema);
|
const mainDomain = generateRandomDomain(schema);
|
||||||
|
|
||||||
|
|
||||||
const apiKey = generateBase64(48);
|
const apiKey = generateBase64(48);
|
||||||
const postgresPassword = generateBase64(24);
|
const postgresPassword = generateBase64(24);
|
||||||
const jwtSecret = generateBase64(24);
|
const jwtSecret = generateBase64(24);
|
||||||
const encryptionKey = generateBase64(12);
|
const encryptionKey = generateBase64(12);
|
||||||
|
const redisPassword = generateBase64(24);
|
||||||
|
|
||||||
const postgresUser = "activepieces";
|
const postgresUser = "activepieces";
|
||||||
const postgresDb = "activepieces";
|
const postgresDb = "activepieces";
|
||||||
@@ -34,6 +34,7 @@ export function generate(schema: Schema): Template {
|
|||||||
`AP_API_KEY=${apiKey}`,
|
`AP_API_KEY=${apiKey}`,
|
||||||
`AP_ENCRYPTION_KEY=${encryptionKey}`,
|
`AP_ENCRYPTION_KEY=${encryptionKey}`,
|
||||||
`AP_JWT_SECRET=${jwtSecret}`,
|
`AP_JWT_SECRET=${jwtSecret}`,
|
||||||
|
`REDIS_PASSWORD=${redisPassword}`,
|
||||||
];
|
];
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user