lucee / lucee-dockerfiles

Official Lucee Dockerfiles for Docker Hub build images
https://hub.docker.com/u/lucee/
MIT License
85 stars 50 forks source link

Use Conventional Image Version Tagging #40

Closed jamiejackson closed 5 years ago

jamiejackson commented 6 years ago

Currently, each Lucee minor version has its own Docker Hub repo; however, this is counterintuitive/unconventional.

For instance lucee/lucee5 should (at the time of this writing) be equivalent to:

Examples of projects that use conventional versioning:

This would require more build plumbing, as noted by @justincarter (on Slack):

@jamiejackson yes each lucee minor version does have it's own repo in docker hub, for the primary reason that we're using automated build triggers

if we drop the docker hub automated build triggers and build a more complex pipeline then we could automate the builds of various different combinations of base image, tomcat version, java version, lucee version the amount of work to get to that point hasn't quite been justified yet, or i haven't had enough free time :slightly_smiling_face: so to upgrade from lucee 5.1 to 5.2 you'd change FROM lucee/lucee51-nginx:latest to FROM lucee/lucee52-nginx:latest

you can see the kinds of additional tools/scripts that need to be implemented for the solr image builds here: https://github.com/docker-solr/docker-solr/tree/afe43e97be7aa764656f3e0aa068bed90f6bdd27/tools

rye commented 6 years ago

Hi! Thanks for providing Dockerfiles for Lucee, it makes Lucee way easier to test out and actually. After finding Lucee, an organization I work for is interested in Dockerizing some of our old ColdFusion apps.

To the point of this Issue, I agree with the sentiment that the current structuring of the lucee repositories on Docker Hub is a bit strange. It sounds from this Issue like the current structure was chosen/emerged from the use of automated build triggers—this is fine, and works pretty well, but does have some drawbacks.

To this end, my colleague, @hawkrives, and I spend the evening working on a new build infrastructure that uses Travis CI instead of Docker Hub automated builds. What this ends up doing is providing a nice, clean manifest file (called matrix.yml, pictured below) which is edited to adjust the various variants of the Lucee Docker images that are built, which can then be turned into a .travis.yml file and pushed into the repository. (We must do this due to a limitation with Travis' support for multidimensional build matrices, and the fact that we can't make build matrices of more than 200 builds.)


You can find:

Some of the highlights of our solution:

There are a couple of things we want to rethink on our work so far, but is approach this the direction that you think would be best? I personally think that building with Travis or some other comparable CI provider offers the greatest flexibility, but I'm not familiar enough with Lucee yet to make a fully informed decision.

For what it's worth, we've tried out some of the images our system is producing with one of our larger apps and it worked! Further testing and scrutiny is obviously required to verify this result, but our changes don't seem to be breaking.

TL;DR/Conclusion: If you're interested, we would love to open a PR on this repository that covers all of our changes, and this would also allow us to give more details as well as get feedback from you!

justincarter commented 6 years ago

That's great work! It's definitely very close to the direction that we want to move in :) The matrix of builds looks really good, we might just want to provide some additional tags for the latest build of each minor version, with the latest supported/recommended Tomcat and JRE, with options for both nginx and Alpine; e.g. "5.2-nginx", "5.2-nginx-alpine", and "5.2-alpine". Maybe "light" as well though I haven't personally used it in Docker images at all yet.

I'm also happy to receive a PR at any time, I'll have some limitations on my time but I'll try to give you feedback as soon as I can. You could also feel free to start a discussion on the Lucee dev forum if there's anything else you think we need to discuss in more detail.

arthurblake commented 6 years ago

@rye does everything work fine perfectly in a Lucee Alpine container? I was curious about doing that myself.

rye commented 6 years ago

@arthurblake, to my cursory testing, it certainly seems so! Because everything is built on Java, I'd imagine the libc doesn't matter.

Apologies for the delay in getting that PR up, I got busy with some other stuff. Should be able to finally submit the PR in a couple of hours.

jamiejackson commented 5 years ago

Is there any update on this?

justincarter commented 5 years ago

Yes, the new repo and tags will be ready for the 5.3 releases, and the existing releases will use the existing repos. I have one more change to make to be able to trigger builds for a particular version number so that we can eventually automate the Docker images builds from the Lucee builds.

On Mon, 8 Oct. 2018, 12:13 am Jamie Jackson, notifications@github.com wrote:

Is there any update on this?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/lucee/lucee-dockerfiles/issues/40#issuecomment-427652490, or mute the thread https://github.com/notifications/unsubscribe-auth/AAVYDYWsbITK0M1df6U9vGXOtL6SYG62ks5uif38gaJpZM4SnP7V .