Skip to content

Commit

Permalink
Copy demo certificates installed to assable's temporary directory
Browse files Browse the repository at this point in the history
  • Loading branch information
QU3B1M committed Nov 12, 2024
1 parent e94a312 commit 594f7b5
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions build-scripts/assemble.sh
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,10 @@ function add_wazuh_tools() {
curl -sL "${download_url}/config.yml" -o "$PATH_PLUGINS"/opensearch-security/tools/config.yml
curl -sL "${download_url}/wazuh-passwords-tool.sh" -o "$PATH_PLUGINS"/opensearch-security/tools/wazuh-passwords-tool.sh
curl -sL "${download_url}/wazuh-certs-tool.sh" -o "$PATH_PLUGINS"/opensearch-security/tools/wazuh-certs-tool.sh
# Include script to install demo certificates
cp distribution/packages/src/common/scripts/install-demo-certificates.sh "$PATH_PLUGINS"/opensearch-security/tools/
}

function add_demo_certs_installer() {
cp install-demo-certificates.sh "$PATH_PLUGINS"/opensearch-security/tools/
}

# ====
Expand Down Expand Up @@ -283,6 +285,7 @@ function assemble_tar() {
# Install plugins
install_plugins "${version}"
fix_log_rotation "${PATH_CONF}"
add_demo_certs_installer
# Swap configuration files
add_configuration_files
remove_unneeded_files
Expand Down Expand Up @@ -323,6 +326,7 @@ function assemble_rpm() {
install_plugins "${version}"
fix_log_rotation ${PATH_CONF}
enable_performance_analyzer_rca ${src_path}
add_demo_certs_installer
# Swap configuration files
add_configuration_files
remove_unneeded_files
Expand Down Expand Up @@ -377,6 +381,7 @@ function assemble_deb() {
install_plugins "${version}"
fix_log_rotation ${PATH_CONF}
enable_performance_analyzer_rca ${src_path}
add_demo_certs_installer
# Swap configuration files
add_configuration_files
remove_unneeded_files
Expand Down Expand Up @@ -422,6 +427,8 @@ function main() {
TMP_DIR="${OUTPUT}/tmp/${TARGET}"
mkdir -p "$TMP_DIR"
cp "${OUTPUT}/dist/$ARTIFACT_BUILD_NAME" "${TMP_DIR}"
# Copy the demo certificates generator
cp distribution/packages/src/common/scripts/install-demo-certificates.sh "$TMP_DIR"

case $PACKAGE in
tar)
Expand Down

0 comments on commit 594f7b5

Please sign in to comment.