beats icon indicating copy to clipboard operation
beats copied to clipboard

[8.19](backport #46562) refactor: remove obsolete "version" property from Docker Compose files

Open mergify[bot] opened this issue 2 months ago • 19 comments

As specified here:

  • https://docs.docker.com/reference/compose-file/version-and-name/#version-top-level-element-obsolete
  • https://github.com/compose-spec/compose-spec/blob/main/spec.md#version-and-name-top-level-elements

See this comment and issue for more context:

  • https://github.com/docker/compose/issues/11628#issuecomment-2075664290

Removing the property gets rid of this warning displayed whenever using the files (e.g. running integration tests):

"the attribute version is obsolete, it will be ignored, please remove it to avoid potential confusion".


This is an automatic backport of pull request #46562 done by Mergify.

mergify[bot] avatar Sep 30 '25 13:09 mergify[bot]

Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane)

elasticmachine avatar Sep 30 '25 13:09 elasticmachine

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Oct 06 '25 04:10 mergify[bot]

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Oct 13 '25 04:10 mergify[bot]

/test

mauri870 avatar Oct 16 '25 11:10 mauri870

@pierrehilbert The failures are unrelated, can you force merge?

mauri870 avatar Oct 16 '25 13:10 mauri870

We should backport https://github.com/elastic/beats/pull/46913 to fix it.

pierrehilbert avatar Oct 17 '25 06:10 pierrehilbert

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Oct 20 '25 04:10 mergify[bot]

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Oct 27 '25 05:10 mergify[bot]

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Nov 03 '25 05:11 mergify[bot]

/test

mauri870 avatar Nov 03 '25 11:11 mauri870

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Nov 10 '25 05:11 mergify[bot]

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Nov 17 '25 05:11 mergify[bot]

I see the following test failures:

=== FAIL: metricbeat/module/aerospike/namespace TestFetch (186.02s) logger.go:146: 2025-11-17T14:32:30.634Z DEBUG docker Docker client will negotiate the API version on the first request. logger.go:146: 2025-11-17T14:32:30.636Z ERROR container remove: Error response from daemon: Conflict, cannot remove the default link name of the container Found orphan containers (metricbeat_8_19_8_d4a5a26c38-snapshot_etcd_1, metricbeat_8_19_8_d4a5a26c38-snapshot_mysql_1) for this project. If you removed or renamed this service in your compose file, you can run this command with the --remove-orphans flag to clean it up.

I'm investigating. Strange that it's not failing the same way on main.

rdner avatar Nov 17 '25 15:11 rdner

In https://github.com/elastic/beats/pull/46856/commits/938341c731ef9758485bd83992a010c4021cad23 I'm trying out something that docker-compose suggested in its output. If it works, I'll open a PR to main with this change and then backport to all active branches.

rdner avatar Nov 17 '25 16:11 rdner

https://github.com/elastic/beats/pull/46856#issuecomment-3542657256 – this didn't help and the tests are passing locally on my machine. I suspect it has something to do with the Docker version itself. I'm reverting https://github.com/elastic/beats/pull/46856/commits/938341c731ef9758485bd83992a010c4021cad23

rdner avatar Nov 17 '25 17:11 rdner

This pull request has not been merged yet. Could you please review and merge it @rdner? 🙏

mergify[bot] avatar Nov 24 '25 05:11 mergify[bot]

/test

rdner avatar Nov 24 '25 16:11 rdner

This pull request has not been merged yet. Could you please review and merge it @rdner? 🙏

mergify[bot] avatar Dec 01 '25 05:12 mergify[bot]

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Dec 08 '25 05:12 mergify[bot]

This pull request has not been merged yet. Could you please review and merge it @andrzej-stencel? 🙏

mergify[bot] avatar Dec 15 '25 05:12 mergify[bot]