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

Fix some issues from #613 #615

Merged
merged 6 commits into from
May 3, 2022
Merged

Conversation

mmlb
Copy link
Contributor

@mmlb mmlb commented May 3, 2022

Description

#613 introduced a few unwanted bits and a typo.

Why is this needed

#613 did not use tools.go setup we have for using pinned go tools.

I reworked it so it also didn't do recursive make as that is considered harmful and setup better dependencies so that we let make be better equipped to do the right thing. This way we avoid using make as a dumb command runner, which if not done can lead to racy/broken makefiles (see hook for example).

I fixed a typo that would cause the manager to use tink-server image, likely to not work :D.

In the process I noticed that we don't have generate-manifests hooked up to be run as part of ci to detect drift, so I added it as a dependency of generated as it should have been from the beginning.

How Has This Been Tested?

I ran make a bunch.

mmlb added 6 commits May 3, 2022 11:05
Signed-off-by: Manuel Mendez <[email protected]>
This way make can generate them in parallel if possible.

Signed-off-by: Manuel Mendez <[email protected]>
This way we won't have out dated k8s manifests.

Also regenerate the manifests.

Signed-off-by: Manuel Mendez <[email protected]>
We shouldn't be patching a git tracked file as part of the build because
then we'd have to go back and checkout the changes. Unfortunately this means
we need to copy the whole directory tree so that kustomize will pick up the
edited files.

I also fixed a typo that used the TINK_SERVER_IMAGE_NAME for the manager.

I also cleaned up the recursive uses of make since they are considered
harmful and dropped `release` as that should be for the whole project not
just the k8s manifests.

Signed-off-by: Manuel Mendez <[email protected]>
@codecov
Copy link

codecov bot commented May 3, 2022

Codecov Report

Merging #615 (d303dc2) into main (ab7fdff) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #615   +/-   ##
=======================================
  Coverage   44.37%   44.37%           
=======================================
  Files          61       61           
  Lines        3491     3491           
=======================================
  Hits         1549     1549           
  Misses       1858     1858           
  Partials       84       84           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ab7fdff...d303dc2. Read the comment docs.

@@ -35,59 +11,55 @@ generate-go: bin/controller-gen bin/gofumpt # Generate Go code.
gofumpt -w -s ./pkg/apis

.PHONY: generate-manifests
generate-manifests: bin/controller-gen # Generate manifests e.g. CRD, RBAC etc.
generate-manifests: generate-crds generate-rbacs generate-server-rbacs # Generate manifests e.g. CRD, RBAC etc.
Copy link
Contributor

Choose a reason for hiding this comment

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

want this to be a doc?

Suggested change
generate-manifests: generate-crds generate-rbacs generate-server-rbacs # Generate manifests e.g. CRD, RBAC etc.
generate-manifests: generate-crds generate-rbacs generate-server-rbacs ## Generate manifests e.g. CRD, RBAC etc.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hmm good catch this was from before I just tacked it onto generate.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oh wait I misread the diff. No I don't think its necessary, make generate will do the right thing. If you'd like it to be documented I have no problem with it showing up in make help. Do you want this to be a doc?

Copy link
Contributor

Choose a reason for hiding this comment

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

Ha It doesn't matter to me. Since this isn't a top level target, I'm fine with keeping it not doc'd

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 thats been my thinking.

@mmlb mmlb added the ready-to-merge Signal to Mergify to merge the PR. label May 3, 2022
@jacobweinstock jacobweinstock removed their request for review May 3, 2022 20:36
@mergify mergify bot merged commit 720195f into tinkerbell:main May 3, 2022
@mmlb mmlb deleted the fix-k8s-release-manifests branch May 3, 2022 21:20
@displague displague added this to the 0.7.0 milestone Aug 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge Signal to Mergify to merge the PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants