feat(database): unify recipe host ports and add Consul, Elasticsearch
This commit is contained in:
49 files changed
+522
-135
No files matched your search
@@ -4,9 +4,9 @@ services:
|
||||
container_name: dbx-nacos-2.5
|
||||
restart: always
|
||||
ports:
|
||||
- "${DB_BIND_ADDRESS:-127.0.0.1}:${DB_PORT:-8849}:8848"
|
||||
- "${DB_BIND_ADDRESS:-127.0.0.1}:${NACOS_GRPC_PORT:-9849}:9848"
|
||||
- "${DB_BIND_ADDRESS:-127.0.0.1}:${NACOS_RAFT_PORT:-9850}:9849"
|
||||
- "${DB_BIND_ADDRESS:-127.0.0.1}:${DB_PORT:-11000}:8848"
|
||||
- "${DB_BIND_ADDRESS:-127.0.0.1}:${NACOS_GRPC_PORT:-11001}:9848"
|
||||
- "${DB_BIND_ADDRESS:-127.0.0.1}:${NACOS_RAFT_PORT:-11002}:9849"
|
||||
environment:
|
||||
MODE: standalone
|
||||
PREFER_HOST_MODE: hostname
|
||||
|
||||
@@ -7,7 +7,8 @@
|
||||
"platforms": ["linux/amd64", "linux/arm64"],
|
||||
"service": "database",
|
||||
"defaultPort": 8848,
|
||||
"connection": { "host": "127.0.0.1", "port": 8849, "username": "nacos", "password": "123456", "database": "dbx", "namespace": "public" },
|
||||
"connection": { "host": "127.0.0.1", "port": 11000, "username": "nacos", "password": "123456", "database": "dbx", "namespace": "public", "grpcPort": 11001, "raftPort": 11002 },
|
||||
"hostPorts": { "DB_PORT": 11000, "NACOS_GRPC_PORT": 11001, "NACOS_RAFT_PORT": 11002 },
|
||||
"bootstrap": {
|
||||
"check": { "command": ["curl", "--fail", "--silent", "--show-error", "--request", "POST", "http://127.0.0.1:8848/nacos/v1/auth/login", "--data-urlencode", "username=nacos", "--data-urlencode", "password=${DB_PASSWORD}"], "expect": "accessToken" },
|
||||
"steps": [{ "name": "initialize administrator password", "command": ["sh", "-ec", "curl --fail --silent --show-error --request POST --data-urlencode \"password=$1\" http://127.0.0.1:8848/nacos/v1/auth/users/admin >/dev/null; curl --fail --silent --show-error --request POST http://127.0.0.1:8848/nacos/v1/auth/login --data-urlencode username=nacos --data-urlencode \"password=$1\" | grep -q '\"accessToken\"'; printf 'administrator initialized\\n'", "sh", "${DB_PASSWORD}"], "expect": "administrator initialized" }]
|
||||
|
||||
Reference in new issue
Block a user