Skip to content

Conversation

@spetersenms
Copy link
Contributor

During the CICD workflow, AL-Go calls https://github.com/microsoft/navcontainerhelper/blob/main/ContainerHandling/Flush-ContainerHelperCache.ps1, which kills any BC container that has been off for 3 days or more, regardless if that container was created by AL-Go.
This scenario can happen if you use self-hosted GitHub runners on the same machine/VM that you use for other BC development.

Related to issue: #1675

@spetersenms spetersenms linked an issue Jul 17, 2025 that may be closed by this pull request
@spetersenms
Copy link
Contributor Author

This PR on the navcontainerhelper side, adds the functionaltiy to check for the AL-Go creator label: microsoft/navcontainerhelper#3983

@spetersenms spetersenms marked this pull request as ready for review August 25, 2025 07:46
Copilot AI review requested due to automatic review settings August 25, 2025 07:46
@spetersenms spetersenms requested a review from a team as a code owner August 25, 2025 07:46
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR prevents AL-Go from purging non-AL-Go Business Central containers during CICD workflows by adding container labeling and selective flushing logic. The change addresses an issue where AL-Go was removing BC containers created by other development processes on self-hosted runners.

Key changes:

  • Modified container creation to add "creator=AL-Go" label to AL-Go containers
  • Added conditional logic to only purge AL-Go containers unless custom container creation is used
  • Moved the cache flushing operation to occur after container configuration

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@spetersenms spetersenms requested a review from mazhelez August 25, 2025 15:50
@spetersenms spetersenms requested a review from aholstrup1 August 27, 2025 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: AL-Go docker pruning too aggressive(?)

2 participants