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

[8.x](backport #5658) Fix docker image build when multiple platforms are specified #5662

Draft
wants to merge 1 commit into
base: 8.x
Choose a base branch
from

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Oct 2, 2024

What does this PR do?

This PR extends the behaviour introduced in #5647 by copying platform-independent components into /archive/ instead of moving them.

This fixes the build of docker image service when multiple platforms are specified for the build: without this fix the platform-independent component would be moved exactly once, in the directory of the first platform considered during the build.

Note:
It seems that EXTERNAL=true SNAPSHOT=true mage package still suffers from some inconsistencies when downloading connectors dependency for multiple platforms but this is unrelated to this fix and will be tracked by a separate issue.

Why is it important?

To correctly build elastic-agent-service docker image for multiple platforms during the Unified Release.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in ./changelog/fragments using the changelog tool
  • I have added an integration test or an E2E test

Disruptive User Impact

How to test this PR locally

Related issues

Questions to ask yourself

  • How are we going to support this in production?
  • How are we going to measure its adoption?
  • How are we going to debug this?
  • What are the metrics I should take care of?
  • ...

This is an automatic backport of pull request #5658 done by [Mergify](https://mergify.com).

Force merging to unblock the unified release process

(cherry picked from commit b8a685c)

# Conflicts:
#	magefile.go
@mergify mergify bot requested a review from a team as a code owner October 2, 2024 09:46
@mergify mergify bot added backport conflicts There is a conflict in the backported pull request labels Oct 2, 2024
@mergify mergify bot requested review from andrzej-stencel and pchila and removed request for a team October 2, 2024 09:46
@mergify mergify bot assigned pchila Oct 2, 2024
Copy link
Contributor Author

mergify bot commented Oct 2, 2024

Cherry-pick of b8a685c has failed:

On branch mergify/bp/8.x/pr-5658
Your branch is up to date with 'origin/8.x'.

You are currently cherry-picking commit b8a685c29c.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   dev-tools/mage/dockerbuilder.go

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   magefile.go

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@pchila
Copy link
Member

pchila commented Oct 2, 2024

This is needed only if the other backport PR #5634 is merged. If that's not the case we can simply close it

@pchila pchila removed the request for review from andrzej-stencel October 2, 2024 12:43
@pierrehilbert pierrehilbert added the Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team label Oct 3, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane)

@pchila
Copy link
Member

pchila commented Oct 4, 2024

Putting this in draft for the moment until we come to a decision about #5634

@pchila pchila marked this pull request as draft October 4, 2024 12:31
Copy link
Contributor Author

mergify bot commented Oct 7, 2024

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport conflicts There is a conflict in the backported pull request Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants