File size: 601 Bytes
ee6ea45
 
 
 
 
 
 
3aee520
ee6ea45
 
 
9d0d51f
 
 
 
 
 
ee6ea45
 
 
 
 
 
 
af4077c
9d0d51f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/bash
# 启动 PostgreSQL 服务
docker-entrypoint.sh postgres &

# 检查 PostgreSQL 服务是否已启动
echo "等待 PostgreSQL 服务启动..."
until pg_isready -h localhost; do
  sleep 3
done
echo "PostgreSQL 服务已启动!"

# 执行数据库导入脚本
echo "运行数据库导入脚本..."
/app/import-db.sh

sleep 3

# export N8N_USER_FOLDER=${DATA_DIR}
export N8N_ENCRYPTION_KEY="n8n8n8n"
# Allows usage of all builtin modules
export NODE_FUNCTION_ALLOW_BUILTIN=*
# Allow usage of external npm modules.
export NODE_FUNCTION_ALLOW_EXTERNAL=*

# 使用绝对路径调用 n8n
exec n8n