ElasticsearchSecurityException[failed to load SSL configuration [xpack.security.http.ssl]]; nested: ElasticsearchException[failed to initialize SSL TrustManager - certificate_authorities file [/usr/share/elasticsearch/config/certificates/ca/ca.crt] does not exist]; nested: NoSuchFileException[/usr/share/elasticsearch/config/certificates/ca/ca.crt];
elasticsearch2 | Likely root cause: java.nio.file.NoSuchFileException: /usr/share/elasticsearch/config/certificates/ca/ca.crt
elasticsearch2 | at java.base/sun.nio.fs.UnixException.translateToIOException(UnixException.java:92)
elasticsearch2 | at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:111)
elasticsearch2 | at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:116)
elasticsearch2 | at java.base/sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:219)
elasticsearch2 | at java.base/java.nio.file.Files.newByteChannel(Files.java:374)
elasticsearch2 | at java.base/java.nio.file.Files.newByteChannel(Files.java:425)
elasticsearch2 | at java.base/java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:420)
elasticsearch2 | at java.base/java.nio.file.Files.newInputStream(Files.java:159)
elasticsearch2 | at org.elasticsearch.xpack.core.ssl.CertParsingUtils.readCertificates(CertParsingUtils.java:97)
elasticsearch2 | at org.elasticsearch.xpack.core.ssl.CertParsingUtils.readCertificates(CertParsingUtils.java:90)
elasticsearch2 | at org.elasticsearch.xpack.core.ssl.PEMTrustConfig.createTrustManager(PEMTrust
I have it in docker-compose,
volumes:
- '/var/lib/pgsql/docker/elasticsearch/data:/usr/share/elasticsearch/data'
- certs:$CERTS_DIR