Skip to content

Comments

Report changed files for Argo steps#1771

Merged
eddymoulton merged 3 commits intomainfrom
em/report-changed-files-for-argo-steps
Feb 16, 2026
Merged

Report changed files for Argo steps#1771
eddymoulton merged 3 commits intomainfrom
em/report-changed-files-for-argo-steps

Conversation

@eddymoulton
Copy link
Contributor

@eddymoulton eddymoulton commented Feb 13, 2026

In #1749 we introduced a service message to report changed files when doing Argo CD deployments, but it did not include the actual changed files/patches that we want to capture.

This PR adds to that existing service message:

  • A hash of each file that is changed (when applicable)
  • Placeholders for sending a JSON patch of changed values (when applicable)

The JSON patch functionality will be completed once we finish up changes to include a JSON patch generator in Calamari.

We will avoid sending sensitive data back to server through:

  • Hashing full files that are changed
  • Only sending JSON patches when we are performing image update steps (only version changes)

Example data (from server side)
image

Closes MD-1511
Relates to MD-1512

@eddymoulton eddymoulton marked this pull request as ready for review February 16, 2026 02:39
Copy link
Contributor

@zentron zentron left a comment

Choose a reason for hiding this comment

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

Im unsure about some of the data model used here, though I know that's not tied to your specific change.

I don't like overloading the ProcessApplicationResult to be used in two different scenarios with different nulled properties. Feels a bit off.

Just a question about the tests

""";

var resultRepo = RepositoryHelpers.CloneOrigin(tempDirectory, OriginPath, argoCDBranchName);
AssertFileContents(resultRepo, "files/values.yml", updatedValuesFile);
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we need to assert the file looks as we expected? I would have thought this would be handled by another test already and this could focus on the jsonpatch info.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, that's a good call out for a copy and paste job. I'll scope down those assertions

@eddymoulton
Copy link
Contributor Author

Im unsure about some of the data model used here, though I know that's not tied to your specific change.

Yeah, you've got a point with this.

I think the model we are passing back to server via the service message works alright - but I did feel a bit uneasy as I was making changes through each of the install conventions. There are places where a misplaced parameter could get through as a bug.

I'll merge this as is, but it's something that I might be able to improve.

@eddymoulton eddymoulton merged commit bc399ae into main Feb 16, 2026
33 checks passed
@eddymoulton eddymoulton deleted the em/report-changed-files-for-argo-steps branch February 16, 2026 21:38
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.

2 participants