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

mainClass and jvmFlags cannot be set lazily on JibExtension in the Gradle plugin #3927

Closed
erdi opened this issue Feb 10, 2023 · 6 comments
Closed

Comments

@erdi
Copy link
Contributor

erdi commented Feb 10, 2023

While many properties on JibExtension utilise lazy configuration APIs, including some of the more complex ones like labels, there are some, including mainClass and jvmFlags, that do not. This forces users of the plugin to have to resort to using Project.afterEvaluate() in certain scenarios.

Would you be willing to accept a PR if I addressed that?

@lqiu96
Copy link

lqiu96 commented Feb 10, 2023

Hi @erdi. Thanks for bringing this up! We do welcome contributions to jib (https://github.com/GoogleContainerTools/jib/blob/master/CONTRIBUTING.md) and we'll gladly review any incoming PRs.

@emmileaf FYI as you may have more context regarding this.

@emmileaf
Copy link
Contributor

Yes, enabling lazy evaluation for more of jib-gradle-plugin’s properties is something we would welcome help from the community on. @erdi As you’ve mentioned, this was previously done for a number of properties such as labels (#3094) and creationTime (#3709), feel free to refer to these discussions and follow a similar approach. Thank you!

@erdi
Copy link
Contributor Author

erdi commented Feb 13, 2023

Thanks for the pointers to related issues/PRs, @emmileaf, they will definitely come handy. Let me see what I can do about this.

@erdi
Copy link
Contributor Author

erdi commented Feb 22, 2023

FYI, @emmileaf, I've just opened a PR with a fix for this issue.

@wakingrufus
Copy link
Contributor

@emmileaf i have opened an additional PR to make entrypoint lazy #4003

@emmileaf
Copy link
Contributor

Hi @wakingrufus, would you mind opening a separate issue to track this feature request and your implementation? I think this issue can be closed with #3936 already merged and released. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants