Skip to content

Commit

Permalink
Add possibility to use system CA
Browse files Browse the repository at this point in the history
  • Loading branch information
poloz-lab committed Feb 10, 2023
1 parent 5f4fc7a commit 9f22d83
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions manifests/dashboard.pp
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@

$manage_certs = true,
$manage_repos = false, # Change to true when manager is not present.
$use_system_ca = false,
) {
if $manage_repos {
include wazuh::repo
Expand Down
1 change: 1 addition & 0 deletions manifests/filebeat_oss.pp
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
$filebeat_path_certs = '/etc/filebeat/certs',

$manage_certs = true,
$use_system_ca = false,
) {
include wazuh::repo_elastic_oss

Expand Down
2 changes: 2 additions & 0 deletions templates/filebeat_oss_yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,10 @@ output.elasticsearch:
username: <%= @filebeat_oss_elastic_user %>
password: <%= @filebeat_oss_elastic_password %>
protocol: https
<% if not @use_system_ca -%>
ssl.certificate_authorities:
- /etc/filebeat/certs/root-ca.pem
<% end -%>
ssl.certificate: "/etc/filebeat/certs/filebeat.pem"
ssl.key: "/etc/filebeat/certs/filebeat-key.pem"

Expand Down
2 changes: 2 additions & 0 deletions templates/wazuh_dashboard_yml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,7 @@ opensearch_security.openid.verify_hostnames: <%= @opensearch_security_openid_ver
server.ssl.enabled: true
server.ssl.key: "<%= @dashboard_path_certs %>/dashboard-key.pem"
server.ssl.certificate: "<%= @dashboard_path_certs %>/dashboard.pem"
<% if not @use_system_ca -%>
opensearch.ssl.certificateAuthorities: ["<%= @dashboard_path_certs %>/root-ca.pem"]
<% end -%>
uiSettings.overrides.defaultRoute: /app/wazuh

0 comments on commit 9f22d83

Please sign in to comment.