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

build: add make docker-generate-protobuf to update genedated *.pb.go files #372

Merged
merged 1 commit into from
Jun 21, 2023

Conversation

nixpanic
Copy link
Collaborator

It seems that not all developers use an updated version of Fedora. For the contributors that need to update *.proto files and re-generate the related *.pb.go files, the new make docker-generate-protobuf command will be very useful.

@mergify mergify bot requested review from Rakshith-R and yati1998 June 20, 2023 13:35
Makefile Outdated
Comment on lines 185 to 186
buildah bud -f $^ -t ${TOOLS_IMG} .
podman run --rm -ti --volume=${PWD}:/go/src/github.com/csi-addons/kubernetes-csi-addons:Z ${TOOLS_IMG} make generate-protobuf
Copy link
Member

Choose a reason for hiding this comment

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

Not all systems will have buildah and podman and we use docker in most places in this Makefile to run commands.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yeah, but Docker is not part of recent Fedora installations anymore, so I only have buildah/podman. I could change it to podman only, and add detection for podman, with a fallback ro docker if you prefer that.

Copy link
Member

Choose a reason for hiding this comment

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

i that would be a good option as some developers might also not use Fedora.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done, please have a look again.

@nixpanic nixpanic requested a review from Madhu-1 June 21, 2023 08:47
Copy link
Contributor

@yati1998 yati1998 left a comment

Choose a reason for hiding this comment

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

LGTM

…go` files

It seems that not all developers use an updated version of Fedora. For
the contributors that need to update `*.proto` files and re-generate the
related `*.pb.go` files, the new `make docker-generate-protobuf` command
will be very useful.

This includes detection for Podman or Docker in the `Makefile`, so that
developers can use euther (Podman recommended!).

Signed-off-by: Niels de Vos <[email protected]>
@mergify mergify bot merged commit 4932221 into csi-addons:main Jun 21, 2023
nixpanic added a commit to nixpanic/kubernetes-csi-addons that referenced this pull request Jun 21, 2023
With recent changes to detect Podman/Docker, the
`docker-generate-protobuf` make target was broken. The parameters to
the container build command were passed like `$^`, and not only the
Containerfile filename.

Fixes: csi-addons#372
Signed-off-by: Niels de Vos <[email protected]>
mergify bot pushed a commit that referenced this pull request Jun 22, 2023
With recent changes to detect Podman/Docker, the
`docker-generate-protobuf` make target was broken. The parameters to
the container build command were passed like `$^`, and not only the
Containerfile filename.

Fixes: #372
Signed-off-by: Niels de Vos <[email protected]>
@nixpanic nixpanic deleted the build/container branch June 23, 2023 11:44
@Rakshith-R Rakshith-R linked an issue Jul 10, 2023 that may be closed by this pull request
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.

update Makefile to generate golang libs for interal protos
3 participants