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

Refactor and document dataInjections #2422

Open
Racer159 opened this issue Apr 6, 2024 · 0 comments
Open

Refactor and document dataInjections #2422

Racer159 opened this issue Apr 6, 2024 · 0 comments
Labels
tech-debt 💳 Debt that the team has charged and needs to repay

Comments

@Racer159
Copy link
Contributor

Racer159 commented Apr 6, 2024

Describe what should be investigated or refactored

Currently dataInjections make a few assumptions that make them less flexible than they could be and that are not documented leading to confusion among users.

I would propose dropping the current data injection marker requirement and instead push users to back the container's target directory with a PV rather than trying to detect the "generation" of a pod to handle the injection. In the current code, if a pod is recycled the injected data would be lost anyway without a PV leading to a brittle configuration - requiring a PV would guide users towards a better practice and would allow data injection to function more generically across components and packages.

The data injection marker itself should still be retained though as a way for an initContainer to determine if it was done receiving data however - and this should also be documented clearly.

Links to any relevant code

https://github.com/defenseunicorns/zarf/blob/main/src/pkg/cluster/data.go#L45

Additional context

This has come up from the community and d 🦄 users as a point of confusion and reason to not use data injections in the past.

@Racer159 Racer159 added the tech-debt 💳 Debt that the team has charged and needs to repay label Apr 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tech-debt 💳 Debt that the team has charged and needs to repay
Projects
Status: No status
Status: New
Development

No branches or pull requests

1 participant