Skip to content

Add logging to Event Log for install, uninstall, and enroll subcommands #6338

@leehinman

Description

@leehinman

Currently we log to the Event Log if the run subcommand fails under Windows. This has been useful in capturing errors from the Windows Service Manager. We should add this same logging to the install, uninstall, and enroll sub-commands. These commands can often be run from DevOps software that make it hard to capture the error.

Code similar to

logExternal(fmt.Sprintf("%s run failed: %s", paths.BinaryName, err))
should be added to install and uninstall

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions