调试 elastic

Signed-off-by: 萌森 <qyg2297248353@163.com>
This commit is contained in:
萌森 2024-07-23 12:54:17 +08:00
parent feca8c24f7
commit a2963ff872
3 changed files with 22 additions and 79 deletions

View File

@ -1,42 +1,17 @@
http.port: 9200 discovery:
transport.port: 9300 type: single-node
http.host: 0.0.0.0 network:
http.cors.enabled: true host: 0.0.0.0
http.cors.allow-origin: "*" http:
network.host: 0.0.0.0 host: 0.0.0.0
path: port: 9200
data: /usr/share/elasticsearch/data cors:
logs: /usr/share/elasticsearch/logs
gateway.recover_after_nodes: 1
cluster.name: ${CLUSTER_NAME}
node.name: ${ES_SETTING_NODE_NAME}
node.master: true
node.ingest: true
node.data: true
#----------------------- BEGIN SECURITY AUTO CONFIGURATION -----------------------
#
# The following settings, TLS certificates, and keys have been automatically
# generated to configure Elasticsearch security features on 23-07-2024 03:18:54
#
# --------------------------------------------------------------------------------
# Enable security features
xpack.security.enabled: true
xpack.security.enrollment.enabled: true
# Enable encryption for HTTP API client connections, such as Kibana, Logstash, and Agents
xpack.security.http.ssl:
enabled: true enabled: true
keystore.path: certs/http.p12 allow-origin: "*"
xpack:
# Enable encryption and mutual authentication between cluster nodes security:
xpack.security.transport.ssl: enabled: true
autoconfiguration:
enabled: true
enrollment:
enabled: true enabled: true
verification_mode: certificate
keystore.path: certs/transport.p12
truststore.path: certs/transport.p12
#----------------------- END SECURITY AUTO CONFIGURATION -------------------------

View File

@ -9,40 +9,18 @@ additionalProperties:
type: text type: text
- default: 9200 - default: 9200
edit: true edit: true
envKey: PANEL_APP_PORT_HTTPS envKey: PANEL_APP_PORT_HTTP
labelZh: WebUI 端口 labelZh: WebUI 端口
labelEn: WebUI port labelEn: WebUI port
required: true required: true
rule: paramPort rule: paramPort
type: number type: number
- default: 9300
edit: true
envKey: PANEL_APP_PORT_API
labelZh: 通讯端口
labelEn: Communication port
required: true
rule: paramPort
type: number
- default: "elasticsearch-cluster"
edit: true
envKey: CLUSTER_NAME
labelZh: 集群名称
labelEn: Cluster name
required: true
type: text
- default: "elasticsearch-node"
edit: true
envKey: ES_SETTING_NODE_NAME
labelZh: 节点名称
labelEn: Node name
required: true
type: text
- default: "" - default: ""
edit: true edit: true
envKey: ELASTIC_PASSWORD envKey: ELASTIC_PASSWORD
labelZh: Elasticsearch 密码 (elastic) labelZh: Elasticsearch 密码 (elastic)
labelEn: Elasticsearch password (elastic) labelEn: Elasticsearch password (elastic)
required: false required: true
type: password type: password
- default: "" - default: ""
edit: true edit: true
@ -51,13 +29,6 @@ additionalProperties:
labelEn: Kibana password (kibana_system) labelEn: Kibana password (kibana_system)
required: false required: false
type: password type: password
- default: ""
edit: true
envKey: ENROLLMENT_TOKEN
labelZh: 注册令牌 (节点)
labelEn: Enrollment token (node)
required: false
type: text
- default: "" - default: ""
edit: true edit: true
envKey: ES_JAVA_OPTS envKey: ES_JAVA_OPTS

View File

@ -22,19 +22,16 @@ services:
soft: 65536 soft: 65536
hard: 65536 hard: 65536
ports: ports:
- ${PANEL_APP_PORT_HTTPS}:9200 - ${PANEL_APP_PORT_HTTP}:9200
- ${PANEL_APP_PORT_API}:9300
env_file: env_file:
- /etc/1panel/envs/global.env - /etc/1panel/envs/global.env
- ${ENV_FILE:-/etc/1panel/envs/default.env} - ${ENV_FILE:-/etc/1panel/envs/default.env}
volumes: volumes:
- ./config/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml - ./config/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml
- ${ELASTICSEARCH_ROOT_PATH}/certs:/usr/share/elasticsearch/config/certs
- ${ELASTICSEARCH_ROOT_PATH}/data:/usr/share/elasticsearch/data - ${ELASTICSEARCH_ROOT_PATH}/data:/usr/share/elasticsearch/data
- ${ELASTICSEARCH_ROOT_PATH}/logs:/usr/share/elasticsearch/logs - ${ELASTICSEARCH_ROOT_PATH}/backup:/usr/share/elasticsearch/backup
- ${ELASTICSEARCH_ROOT_PATH}/plugins:/usr/share/elasticsearch/plugins - ${ELASTICSEARCH_ROOT_PATH}/plugins:/usr/share/elasticsearch/plugins
environment: environment:
- LICENSE=basic - LICENSE=basic
- ES_SETTING_BOOTSTRAP_MEMORY__LOCK=true
- TAKE_FILE_OWNERSHIP=true - TAKE_FILE_OWNERSHIP=true
- CLUSTER_INITIAL__MASTER__NODES=${ES_SETTING_NODE_NAME} - ES_SETTING_BOOTSTRAP_MEMORY__LOCK=true