parent
aafb25eb8c
commit
95d29c74c8
|
|
@ -0,0 +1,40 @@
|
|||
additionalProperties:
|
||||
formFields:
|
||||
- default: "/home/postgres"
|
||||
edit: true
|
||||
envKey: POSTGRES_ROOT_PATH
|
||||
labelZh: 数据持久化路径
|
||||
labelEn: Data persistence path
|
||||
required: true
|
||||
type: text
|
||||
- default: ""
|
||||
edit: false
|
||||
envKey: POSTGRES_PASSWORD
|
||||
labelZh: Postgres 密码 (首次生效)
|
||||
labelEn: Postgres Password (First Time)
|
||||
required: true
|
||||
random: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default: 5432
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelZh: Postgres 端口
|
||||
labelEn: Postgres Port
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_USER
|
||||
labelZh: Postgres 用户(不建议改动)
|
||||
labelEn: Postgres User
|
||||
required: false
|
||||
type: text
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_DB
|
||||
labelZh: Postgres 数据库名称(不建议改动)
|
||||
labelEn: Postgres Database Name
|
||||
required: false
|
||||
type: text
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
networks:
|
||||
1panel-network:
|
||||
external: true
|
||||
|
||||
services:
|
||||
postgresql:
|
||||
image: postgres:16.4-alpine
|
||||
container_name: pg16-alpine-${CONTAINER_NAME}
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
restart: always
|
||||
networks:
|
||||
- 1panel-network
|
||||
ports:
|
||||
- ${PANEL_APP_PORT_HTTP}:5432
|
||||
env_file:
|
||||
- /etc/1panel/envs/global.env
|
||||
- ${ENV_FILE:-/etc/1panel/envs/default.env}
|
||||
volumes:
|
||||
- ${POSTGRES_ROOT_PATH}/data:/var/lib/postgresql/data
|
||||
environment:
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||
POSTGRES_USER: ${POSTGRES_USER:-postgres}
|
||||
POSTGRES_DB: ${POSTGRES_DB:-postgres}
|
||||
POSTGRES_INITDB_ARGS: "--data-checksums"
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
additionalProperties:
|
||||
formFields:
|
||||
- default: "/home/postgres"
|
||||
edit: true
|
||||
envKey: POSTGRES_ROOT_PATH
|
||||
labelZh: 数据持久化路径
|
||||
labelEn: Data persistence path
|
||||
required: true
|
||||
type: text
|
||||
- default: ""
|
||||
edit: false
|
||||
envKey: POSTGRES_PASSWORD
|
||||
labelZh: Postgres 密码 (首次生效)
|
||||
labelEn: Postgres Password (First Time)
|
||||
required: true
|
||||
random: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default: 5432
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelZh: Postgres 端口
|
||||
labelEn: Postgres Port
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_USER
|
||||
labelZh: Postgres 用户(不建议改动)
|
||||
labelEn: Postgres User
|
||||
required: false
|
||||
type: text
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_DB
|
||||
labelZh: Postgres 数据库名称(不建议改动)
|
||||
labelEn: Postgres Database Name
|
||||
required: false
|
||||
type: text
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
networks:
|
||||
1panel-network:
|
||||
external: true
|
||||
|
||||
services:
|
||||
postgresql:
|
||||
image: postgres:16.4
|
||||
container_name: pg16-${CONTAINER_NAME}
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
restart: always
|
||||
networks:
|
||||
- 1panel-network
|
||||
ports:
|
||||
- ${PANEL_APP_PORT_HTTP}:5432
|
||||
env_file:
|
||||
- /etc/1panel/envs/global.env
|
||||
- ${ENV_FILE:-/etc/1panel/envs/default.env}
|
||||
volumes:
|
||||
- ${POSTGRES_ROOT_PATH}/data:/var/lib/postgresql/data
|
||||
environment:
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||
POSTGRES_USER: ${POSTGRES_USER:-postgres}
|
||||
POSTGRES_DB: ${POSTGRES_DB:-postgres}
|
||||
POSTGRES_INITDB_ARGS: "--data-checksums"
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
additionalProperties:
|
||||
formFields:
|
||||
- default: "/home/postgres"
|
||||
edit: true
|
||||
envKey: POSTGRES_ROOT_PATH
|
||||
labelZh: 数据持久化路径
|
||||
labelEn: Data persistence path
|
||||
required: true
|
||||
type: text
|
||||
- default: ""
|
||||
edit: false
|
||||
envKey: POSTGRES_PASSWORD
|
||||
labelZh: Postgres 密码 (首次生效)
|
||||
labelEn: Postgres Password (First Time)
|
||||
required: true
|
||||
random: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default: 5432
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelZh: Postgres 端口
|
||||
labelEn: Postgres Port
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_USER
|
||||
labelZh: Postgres 用户(不建议改动)
|
||||
labelEn: Postgres User
|
||||
required: false
|
||||
type: text
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_DB
|
||||
labelZh: Postgres 数据库名称(不建议改动)
|
||||
labelEn: Postgres Database Name
|
||||
required: false
|
||||
type: text
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
networks:
|
||||
1panel-network:
|
||||
external: true
|
||||
|
||||
services:
|
||||
postgresql:
|
||||
image: postgres:17.0-alpine
|
||||
container_name: pg17-alpine-${CONTAINER_NAME}
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
restart: always
|
||||
networks:
|
||||
- 1panel-network
|
||||
ports:
|
||||
- ${PANEL_APP_PORT_HTTP}:5432
|
||||
env_file:
|
||||
- /etc/1panel/envs/global.env
|
||||
- ${ENV_FILE:-/etc/1panel/envs/default.env}
|
||||
volumes:
|
||||
- ${POSTGRES_ROOT_PATH}/data:/var/lib/postgresql/data
|
||||
environment:
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||
POSTGRES_USER: ${POSTGRES_USER:-postgres}
|
||||
POSTGRES_DB: ${POSTGRES_DB:-postgres}
|
||||
POSTGRES_INITDB_ARGS: "--data-checksums"
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
additionalProperties:
|
||||
formFields:
|
||||
- default: "/home/postgres"
|
||||
edit: true
|
||||
envKey: POSTGRES_ROOT_PATH
|
||||
labelZh: 数据持久化路径
|
||||
labelEn: Data persistence path
|
||||
required: true
|
||||
type: text
|
||||
- default: ""
|
||||
edit: false
|
||||
envKey: POSTGRES_PASSWORD
|
||||
labelZh: Postgres 密码 (首次生效)
|
||||
labelEn: Postgres Password (First Time)
|
||||
required: true
|
||||
random: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default: 5432
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelZh: Postgres 端口
|
||||
labelEn: Postgres Port
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_USER
|
||||
labelZh: Postgres 用户(不建议改动)
|
||||
labelEn: Postgres User
|
||||
required: false
|
||||
type: text
|
||||
- default: "postgres"
|
||||
edit: false
|
||||
envKey: POSTGRES_DB
|
||||
labelZh: Postgres 数据库名称(不建议改动)
|
||||
labelEn: Postgres Database Name
|
||||
required: false
|
||||
type: text
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
networks:
|
||||
1panel-network:
|
||||
external: true
|
||||
|
||||
services:
|
||||
postgresql:
|
||||
image: postgres:17.0
|
||||
container_name: pg17-${CONTAINER_NAME}
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
restart: always
|
||||
networks:
|
||||
- 1panel-network
|
||||
ports:
|
||||
- ${PANEL_APP_PORT_HTTP}:5432
|
||||
env_file:
|
||||
- /etc/1panel/envs/global.env
|
||||
- ${ENV_FILE:-/etc/1panel/envs/default.env}
|
||||
volumes:
|
||||
- ${POSTGRES_ROOT_PATH}/data:/var/lib/postgresql/data
|
||||
environment:
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||
POSTGRES_USER: ${POSTGRES_USER:-postgres}
|
||||
POSTGRES_DB: ${POSTGRES_DB:-postgres}
|
||||
POSTGRES_INITDB_ARGS: "--data-checksums"
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -f .env ]; then
|
||||
source .env
|
||||
|
||||
# setup-1 add default values
|
||||
CURRENT_DIR=$(pwd)
|
||||
sed -i '/^ENV_FILE=/d' .env
|
||||
echo "ENV_FILE=${CURRENT_DIR}/.env" >> .env
|
||||
|
||||
echo "Check Finish."
|
||||
|
||||
else
|
||||
echo "Error: .env file not found."
|
||||
fi
|
||||
Loading…
Reference in New Issue