diff --git a/dev-tools/packaging/packages.yml b/dev-tools/packaging/packages.yml index dbfbc9f4b7a..aedcd81eb7f 100644 --- a/dev-tools/packaging/packages.yml +++ b/dev-tools/packaging/packages.yml @@ -284,12 +284,6 @@ shared: <<: *common files: <<: *agent_binary_files - install-service-{{.BeatName}}.ps1: - template: '{{ elastic_beats_dir }}/dev-tools/packaging/templates/windows/install-service-elastic-agent.ps1.tmpl' - mode: 0755 - uninstall-service-{{.BeatName}}.ps1: - template: '{{ elastic_beats_dir }}/dev-tools/packaging/templates/windows/uninstall-service.ps1.tmpl' - mode: 0755 'data/{{.BeatName}}-{{ commit_short }}/downloads/filebeat-{{ beat_version }}{{if .Snapshot}}-SNAPSHOT{{end}}-{{.GOOS}}-{{.AgentArchName}}.zip': source: '{{.AgentDropPath}}/filebeat-{{ beat_version }}{{if .Snapshot}}-SNAPSHOT{{end}}-{{.GOOS}}-{{.AgentArchName}}.zip' mode: 0644 diff --git a/dev-tools/packaging/templates/windows/install-service-elastic-agent.ps1.tmpl b/dev-tools/packaging/templates/windows/install-service-elastic-agent.ps1.tmpl deleted file mode 100644 index fe037e3b425..00000000000 --- a/dev-tools/packaging/templates/windows/install-service-elastic-agent.ps1.tmpl +++ /dev/null @@ -1,19 +0,0 @@ -$ErrorActionPreference = "Stop" - -# Delete and stop the service if it already exists. -if (Get-Service {{.BeatName}} -ErrorAction SilentlyContinue) { - $service = Get-WmiObject -Class Win32_Service -Filter "name='{{.BeatName}}'" - $service.StopService() - Start-Sleep -s 1 - $service.delete() -} - -$workdir = Split-Path $MyInvocation.MyCommand.Path - -# Create the new service. -New-Service -name {{.BeatName}} ` - -displayName {{.BeatName | title}} ` - -binaryPathName "`"$workdir\{{.BeatName}}.exe`" --path.home `"$workdir`" --path.data `"$workdir\data`" run" - -# Start the new service. -Start-Service -name {{.BeatName}} diff --git a/x-pack/elastic-agent/CHANGELOG.next.asciidoc b/x-pack/elastic-agent/CHANGELOG.next.asciidoc index 73dfe8ff9a4..0a38b625f63 100644 --- a/x-pack/elastic-agent/CHANGELOG.next.asciidoc +++ b/x-pack/elastic-agent/CHANGELOG.next.asciidoc @@ -34,3 +34,4 @@ - Add `elastic.agent.id` and `elastic.agent.version` to published events from filebeat and metricbeat {pull}21543[21543] - Add `upgrade` subcommand to perform upgrade of installed Elastic Agent {pull}21425[21425] - Update `fleet.yml` and Kibana hosts when a policy change updates the Kibana hosts {pull}21599[21599] +- Removed `install-service.ps1` and `uninstall-service.ps1` from Windows .zip packaging {pull}21694[21694]