Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix enrollment system tests #4562

Merged
merged 2 commits into from
Sep 28, 2023
Merged

Conversation

juliamagan
Copy link
Member

@juliamagan juliamagan commented Sep 28, 2023

Related issue
#4552

Description

We've found that the test's function clear_file() is creating a new file etc/ossec.log with these permissions:

rw--r--r-- root root

This means that wazuh-agentd is unable to write into ossec.log after dropping its permissions.

Updated

  • Clear ossec.log after yield, so the file exists and it isn't created with wrong permissions.

Testing performed

  • 🟢 test_cluster/test_agent_enrollment
  • 🟢 test_enrollment

@juliamagan juliamagan self-assigned this Sep 28, 2023
@juliamagan juliamagan linked an issue Sep 28, 2023 that may be closed by this pull request
Copy link
Contributor

@verdx verdx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@juliamagan juliamagan merged commit 53b52e5 into 4.5.3 Sep 28, 2023
4 checks passed
@juliamagan juliamagan deleted the bug/4552-enrollment-system-tests branch September 28, 2023 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

System tests fail on agent enrollment
2 participants