Skip to content

Commit

Permalink
rename log file for agent publish scenario (#2956)
Browse files Browse the repository at this point in the history
* rename log file

* add param

* address comment
  • Loading branch information
nagworld9 authored Nov 8, 2023
1 parent 5542f84 commit 9324a89
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests_e2e/tests/agent_publish/agent_publish.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@ def _get_agent_info(self) -> None:
log.info('Agent info \n%s', stdout)

def _prepare_agent(self) -> None:
log.info("Modifying agent update related config flags")
self._run_remote_test(self._ssh_client, "update-waagent-conf Debug.DownloadNewAgents=y AutoUpdate.GAFamily=Test AutoUpdate.Enabled=y Extensions.Enabled=y", use_sudo=True)
log.info('Updated agent-update DownloadNewAgents GAFamily config flags')
log.info("Modifying agent update related config flags and renaming the log file")
self._run_remote_test(self._ssh_client, "sh -c 'agent-service stop && mv /var/log/waagent.log /var/log/waagent.$(date --iso-8601=seconds).log && update-waagent-conf Debug.DownloadNewAgents=y AutoUpdate.GAFamily=Test AutoUpdate.Enabled=y Extensions.Enabled=y'", use_sudo=True)
log.info('Renamed log file and updated agent-update DownloadNewAgents GAFamily config flags')

def _check_update(self) -> None:
log.info("Verifying for agent update status")
Expand Down

0 comments on commit 9324a89

Please sign in to comment.