-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
#5950 Pulling up user creation in Dockerfile for layer caching #6002
Conversation
Not sure how to test this. I did the change first in an actual project and can confirm it works there. But of course I could have messed up when transferring the change into the template. Is there an easy way I can materialize the template again so to see whether it's working correctly? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added a minor comment, looks good otherwise
devtools/platform-descriptor-json/src/main/resources/templates/dockerfile-jvm.ftl
Outdated
Show resolved
Hide resolved
You can test the new templates by generating a project according to what has been documented in at: 4dec5b8 |
Force-pushed for the typo fix. Thx for the hint on snapshot testing. Will
do later today and report back.
… |
Great, thanks! |
It's minor but it the second time you do it IIRC: could we avoid the Thanks. |
No problem, I can remove it If you prefer. NB it's intentionally done to
indicate that there's more in the message than the leading line, which I
find a useful hint as in many places you only get shown the first line of
commit messages.
|
Well, it won't work very well in a project with 200 committers and you're the only one doing it :). Let's get rid of it. |
In case of rebuilding an image, the create user command would run again before, as it came after the more volatile commands for adding dependencies and runner.
Obviously, the 199 others should do as I do ;) Until then, I've removed it. Also tested the snapshot template version as suggested by @geoand. All looks good, here's the log showing how the ADD USER command is cached after a code change:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @gunnarmorling!!!
@gsmet do you plan on backporting this one? |
I haven't created the branch yet tbh. If you think that's something we should have in 1.1, let's merge it once CI is green. |
Merged, thanks. |
In case of rebuilding an image, the create user command would run again before, as it came after the more volatile commands for adding dependencies and runner.
Fixes: #5950