diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 90fa0883..43d80c5c 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -109,7 +109,7 @@ jobs: exit 1 fi status_index="`curl -XGET "https://0.0.0.0:9200/_cat/indices" -u admin:SecretPassword -k -s | wc -l`" - status_index_green="`curl -XGET "https://0.0.0.0:9200/_cat/indices" -u admin:SecretPassword -k -s | grep -E "green" | wc -l`" + status_index_green="`curl -XGET "https://0.0.0.0:9200/_cat/indices" -u admin:SecretPassword -k -s | grep "green" | wc -l`" if [[ $status_index_green -eq $status_index ]]; then curl -XGET "https://0.0.0.0:9200/_cat/indices" -u admin:SecretPassword -k -s else @@ -140,8 +140,8 @@ jobs: - name: Check Wazuh templates run: | - qty_templates="`curl -XGET "https://0.0.0.0:9200/_cat/templates" -u admin:SecretPassword -k -s | grep -E "wazuh ||wazuh-agent||wazuh-statistics" | wc -l`" - templates="`curl -XGET "https://0.0.0.0:9200/_cat/templates" -u admin:SecretPassword -k -s | grep -E "wazuh ||wazuh-agent||wazuh-statistics"`" + qty_templates="`curl -XGET "https://0.0.0.0:9200/_cat/templates" -u admin:SecretPassword -k -s | grep -P "wazuh|wazuh-agent|wazuh-statistics" | wc -l`" + templates="`curl -XGET "https://0.0.0.0:9200/_cat/templates" -u admin:SecretPassword -k -s | grep -P "wazuh|wazuh-agent|wazuh-statistics"`" if [[ $qty_templates -eq 3 ]]; then echo "wazuh templates:" echo "${templates}" @@ -266,7 +266,7 @@ jobs: run: | qty_templates="`curl -XGET "https://0.0.0.0:9200/_cat/templates" -u admin:SecretPassword -k -s | grep "wazuh" | wc -l`" templates="`curl -XGET "https://0.0.0.0:9200/_cat/templates" -u admin:SecretPassword -k -s | grep "wazuh"`" - if [[ $qty_templates -gt 0 ]]; then + if [[ $qty_templates -eq 3 ]]; then echo "wazuh templates:" echo "${templates}" else diff --git a/build-docker-images/build-images.sh b/build-docker-images/build-images.sh index b8da9c7b..10105990 100755 --- a/build-docker-images/build-images.sh +++ b/build-docker-images/build-images.sh @@ -6,7 +6,7 @@ WAZUH_ACTUAL_VERSION=$(curl --silent https://api.github.com/repos/wazuh/wazuh/re if [ "$WAZUH_VERSION" -le "$WAZUH_ACTUAL_VERSION" ]; then IMAGE_VERSION=${WAZUH_IMAGE_VERSION} else - IMAGE_VERSION=${WAZUH_IMAGE_VERSION}-dev + IMAGE_VERSION=${WAZUH_IMAGE_VERSION} fi echo WAZUH_VERSION=$WAZUH_IMAGE_VERSION > .env