docker-compose.yml
version: '3.1'
services:
solr:
build: ikanalyzer
restart: always
container_name: solr
ports:
- 8983:8983
volumes:
- ./solrdata:/opt/solrdata
Dockerfile
FROM solr
MAINTAINER Lusifer <topsale@vip.qq.com>
# 创建 Core
WORKDIR /opt/solr/server/solr
USER root
RUN mkdir ik_core
WORKDIR /opt/solr/server/solr/ik_core
RUN echo 'name=ik_core' > core.properties
RUN mkdir data
RUN cp -r ../configsets/sample_techproducts_configs/conf/ .
# 安装中文分词
WORKDIR /opt/solr/server/solr-webapp/webapp/WEB-INF/lib
ADD ik-analyzer-solr5-5.x.jar .
ADD solr-analyzer-ik-5.1.0.jar .
WORKDIR /opt/solr/server/solr-webapp/webapp/WEB-INF
ADD ext.dic .
ADD stopword.dic .
ADD IKAnalyzer.cfg.xml .
# 增加分词配置
COPY managed-schema /opt/solr/server/solr/ik_core/conf
WORKDIR /opt/solr
但是当我跑起来的时候,却报下面的错误
Starting Solr
The currently defined JAVA_HOME (/usr/local/openjdk-11) refers to a location
where java was found but jstack was not found. Continuing.
WARNING: Starting Solr as the root user is a security risk and not considered best practice. Exiting.
Please consult the Reference Guide. To override this check, start with argument '-force'
我应该怎么办?