Skip to content

Not specifying atlasTeams in project spec removes pre existing teams from project #2250

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

Open
RafaelBroseghini opened this issue Apr 4, 2025 · 1 comment

Comments

@RafaelBroseghini
Copy link

What did you do to encounter the bug?
Applying a project with teams managed outside of k8s and empty project.spec.teams unassigns all teams from project.

What did you expect?
I would expect the operator to only manage the teams it has knowledge of, perhaps via status.

What happened instead?
All teams managed outside k8s get unassigned from project.

Operator Information

  • 2.8.0

Additional context
I will give more context on the underlying issue: User invitation + invitation acceptance detection + team assignment cannot be managed via the operator, so we're looking at potentially a different way of managing that flow, which leads to trying to manage atlas team outside the operator.

The project controller tries to reconcile all team assignments vs the project spec when in my opinion it should try to reconcile against what the project object knowledge of, perhaps via status. This is where it detects what to delete:

desiredTeam, ok := teamsToAssign[atlasAssignedTeam.TeamID]
if !ok {
toDelete = append(toDelete, &atlasAssignedTeam)
continue
}

@roothorp
Copy link
Collaborator

roothorp commented Apr 7, 2025

Hi @RafaelBroseghini, thanks for the issue and the details! We are looking into this and will respond here as soon as we have more info.

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

No branches or pull requests

2 participants