Bump to 1.0.12 with Java 21 and plugin automation
This commit is contained in:
@@ -4,7 +4,7 @@
|
|||||||
"author": "Elastic and Cloudron Community",
|
"author": "Elastic and Cloudron Community",
|
||||||
"description": "Elasticsearch is a distributed, open source search and analytics engine for all types of data. This package is designed for internal use only.",
|
"description": "Elasticsearch is a distributed, open source search and analytics engine for all types of data. This package is designed for internal use only.",
|
||||||
"tagline": "Distributed search and analytics engine",
|
"tagline": "Distributed search and analytics engine",
|
||||||
"version": "1.0.7",
|
"version": "1.0.12",
|
||||||
"healthCheckPath": "/_cluster/health?pretty",
|
"healthCheckPath": "/_cluster/health?pretty",
|
||||||
"httpPort": 9200,
|
"httpPort": 9200,
|
||||||
"manifestVersion": 2,
|
"manifestVersion": 2,
|
||||||
|
|||||||
@@ -35,7 +35,10 @@ RUN mkdir -p /usr/share/elasticsearch && \
|
|||||||
|
|
||||||
# Create necessary directories
|
# Create necessary directories
|
||||||
RUN mkdir -p /app/data/{elasticsearch,logs,config,secrets,jdk/bin,run} && \
|
RUN mkdir -p /app/data/{elasticsearch,logs,config,secrets,jdk/bin,run} && \
|
||||||
chown -R elasticsearch:elasticsearch /app/data
|
mkdir -p /app/data/elasticsearch/plugins && \
|
||||||
|
chown -R elasticsearch:elasticsearch /app/data && \
|
||||||
|
rm -rf /usr/share/elasticsearch/plugins && \
|
||||||
|
ln -s /app/data/elasticsearch/plugins /usr/share/elasticsearch/plugins
|
||||||
|
|
||||||
# Copy configuration files
|
# Copy configuration files
|
||||||
COPY elasticsearch.yml /app/elasticsearch.yml
|
COPY elasticsearch.yml /app/elasticsearch.yml
|
||||||
|
|||||||
17
start.sh
17
start.sh
@@ -137,6 +137,15 @@ configure_elasticsearch() {
|
|||||||
chown -R elasticsearch:elasticsearch $ES_PATH_CONF
|
chown -R elasticsearch:elasticsearch $ES_PATH_CONF
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
ensure_directory_structure
|
||||||
|
clean_legacy_settings
|
||||||
|
ensure_setting "xpack.security.http.ssl.enabled" "false"
|
||||||
|
ensure_setting "network.host" "0.0.0.0"
|
||||||
|
ensure_setting "discovery.type" "single-node"
|
||||||
|
ensure_setting "path.data" "/app/data/elasticsearch"
|
||||||
|
ensure_setting "path.logs" "/app/data/logs"
|
||||||
|
ensure_setting "path.plugins" "/app/data/elasticsearch/plugins"
|
||||||
|
|
||||||
# CRITICAL FIX: Remove any index-level settings from elasticsearch.yml to prevent startup failure
|
# CRITICAL FIX: Remove any index-level settings from elasticsearch.yml to prevent startup failure
|
||||||
if [ -f $ES_PATH_CONF/elasticsearch.yml ]; then
|
if [ -f $ES_PATH_CONF/elasticsearch.yml ]; then
|
||||||
echo "Checking elasticsearch.yml for index-level settings..."
|
echo "Checking elasticsearch.yml for index-level settings..."
|
||||||
@@ -375,13 +384,17 @@ setup_keystore() {
|
|||||||
|
|
||||||
# Ensure writable dirs exist
|
# Ensure writable dirs exist
|
||||||
ensure_directory_structure() {
|
ensure_directory_structure() {
|
||||||
mkdir -p /app/data/elasticsearch/{data,plugins}
|
mkdir -p /app/data/elasticsearch
|
||||||
|
mkdir -p /app/data/elasticsearch/plugins
|
||||||
mkdir -p /app/data/logs
|
mkdir -p /app/data/logs
|
||||||
chown -R elasticsearch:elasticsearch /app/data/elasticsearch
|
chown -R elasticsearch:elasticsearch /app/data/elasticsearch /app/data/logs
|
||||||
}
|
}
|
||||||
|
|
||||||
clean_legacy_settings() {
|
clean_legacy_settings() {
|
||||||
sed -i '/^path\.home:/d' "$ES_PATH_CONF/elasticsearch.yml"
|
sed -i '/^path\.home:/d' "$ES_PATH_CONF/elasticsearch.yml"
|
||||||
|
sed -i '/^path\.data:/d' "$ES_PATH_CONF/elasticsearch.yml"
|
||||||
|
sed -i '/^path\.logs:/d' "$ES_PATH_CONF/elasticsearch.yml"
|
||||||
|
sed -i '/^path\.plugins:/d' "$ES_PATH_CONF/elasticsearch.yml"
|
||||||
}
|
}
|
||||||
|
|
||||||
ensure_setting() {
|
ensure_setting() {
|
||||||
|
|||||||
Reference in New Issue
Block a user