wazuh / wazuh-kubernetes

Wazuh - Wazuh Kubernetes
https://wazuh.com/
GNU General Public License v2.0
270 stars 166 forks source link

Generate-certs.sh for Dashboard fails with "error, no objects specified in config file" #352

Open sgl-mnrch opened 1 year ago

sgl-mnrch commented 1 year ago

When I try to run the generate-certs.sh file as described in the docs I get the following error:

❯ cd ../dashboard_http
❯ ./generate_certs.sh
Generating a 2048 bit RSA private key
...........................................................................................+++++
.+++++
writing new private key to 'key.pem'
-----
error, no objects specified in config file
problems making Certificate Request

Running the script for the cluster works. There is also a dashboard.pem created, so I wonder why we need the http one.

CyDickey-msr commented 1 year ago

I ran into the same problem. Running certs/dashboard_http/generate_certs.sh generated key.pem, but not cert.pem.

Both this doc, this doc, and kustomization.yml mention both certs.

https://github.com/openssl/openssl/issues/3536 provided some insight. Running openssl req -x509 -batch -nodes -days 365 -newkey rsa:2048 -keyout key.pem -out cert.pem -subj "/" generated a cert.pem for me.

Usesir112 commented 2 months ago

Try to install openssl (brew install openssl) and retry generate again. It work for me 😀

gecube commented 1 month ago

Don't you want to try #577 ? I just rebased it to the latest master and it works for me like a charm.