Hello,
I hope someone can help me with this.
I have Graylog 3.1; mongodb 4; elasticsearch 6
I run graylog with docker-compose.
Graylog was running with Http.
I tried adding Https and followed the Guide for graylog 3.1
When I try to start docker-compose up I get this Error:
graylog_1 | 2020-02-07 14:27:33,809 ERROR: org.graylog2.bootstrap.CmdLineTool - Invalid configuration
graylog_1 | com.github.joschi.jadconfig.ValidationException: Unreadable or missing HTTP private key: /etc/docker/certs/graylog-key.pem
graylog_1 | at org.graylog2.configuration.HttpConfiguration.validateTlsConfig(HttpConfiguration.java:252) ~[graylog.jar:?]
graylog_1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_232]
graylog_1 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_232]
graylog_1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_232]
graylog_1 | at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_232]
My Docker-Compose.yml looks like this:
graylog:
image: graylog/graylog:3.1
environment:
- "GRAYLOG_SERVER_JAVA_OPTS=-Xms1g -Xmx1g -XX:NewRatio=1 -server -XX:+ResizeTLAB -XX:+UseConcMarkSweepGC -XX:+CMSConcurrentMTEnabled -XX:+CMSClassUnloadingEnabled -XX:-OmitStackTraceInFastThrow -Djavax.net.ssl.trustStore=/etc/docker/certs/cacerts.jks"
- GRAYLOG_HTTP_ENABLE_TLS=true
- GRAYLOG_HTTP_TLS_CERT_FILE=/etc/docker/certs/graylog-cert.pem
- GRAYLOG_HTTP_TLS_KEY_FILE=/etc/docker/certs/graylog-key.pem
- GRAYLOG_HTTP_TLS_KEY_PASSWORD=...
- GRAYLOG_HTTP_PUBLISH_URI=https://{IPAddress}:9000/
- GRAYLOG_PASSWORD_SECRET=...
- GRAYLOG_ROOT_PASSWORD_SHA2=...
- GRAYLOG_HTTP_EXTERNAL_URI=https://{IPAddress}:9000/
the permissions for the files looks like this:
drwxr-xr-x graylog docker certs -rw-r--r-- root root graylog-cert.pem
drwxr-xr-x root root certs -rwxrwxrwx root root graylog-key.pem
I tried both with root:root and with graylog:docker.
I redid the certificate and the key (the key is pkcs8):
Key:
-----BEGIN ENCRYPTED PRIVATE KEY----- GXG0jqxa9k1xx0evlU0nDUg -----END ENCRYPTED PRIVATE KEY-----
Cert:
-----BEGIN CERTIFICATE-----
…Zmb+y76acEqf2yqbXo=
-----END CERTIFICATE-----
I added graylog-cert.pem to the copied cacert.jks
I feel like I am just missing something very obvious but after spending quite some time searching I hope someone can help me with my problem.
If something else is needed I will gladly provide that.