Skip to content

Comments

docker: re-structure build stages for Ubuntu with and without GUI to optimize caching#6534

Merged
ninsbl merged 13 commits intoOSGeo:mainfrom
ninsbl:ubuntu_gui_layers
Oct 23, 2025
Merged

docker: re-structure build stages for Ubuntu with and without GUI to optimize caching#6534
ninsbl merged 13 commits intoOSGeo:mainfrom
ninsbl:ubuntu_gui_layers

Conversation

@ninsbl
Copy link
Member

@ninsbl ninsbl commented Oct 21, 2025

Docker build cache can now be utilized if Ubuntu images are built incrementaly (e.g. first with and then without GUI, or the other way around). Time consuming compilation of dependencies is in a shared layer. GUI tested locally.

@ninsbl ninsbl added this to the 8.4.2 milestone Oct 21, 2025
@ninsbl ninsbl added docker Docker related backport to 8.4 PR needs to be backported to release branch 8.4 labels Oct 21, 2025
@ninsbl ninsbl requested a review from echoix October 21, 2025 13:21
Copy link
Member

@echoix echoix left a comment

Choose a reason for hiding this comment

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

The reordering of the Dockerfile should be working, but the gui logic path isn't ever used now in CI. That was my idea behind the #6512. Currently, it is using a separate ubuntu_wxgui Dockerfile.

Was your plan to have the Dockerfile changes merged first?

@echoix
Copy link
Member

echoix commented Oct 21, 2025

The other gui Dockerfile uses newer wxPython from pip (and the wxPython wheels from their website). I fixed it the other day when upgrading to Ubuntu 24.04.

@ninsbl
Copy link
Member Author

ninsbl commented Oct 21, 2025

Was your plan to have the Dockerfile changes merged first?

Yes, that was my thought. I can remove the "fix" keyword from the PR description if the issue was more about putting the different stages to good use in CI ...

@ninsbl
Copy link
Member Author

ninsbl commented Oct 21, 2025

The other gui Dockerfile uses newer wxPython from pip (and the wxPython wheels from their website). I fixed it the other day when upgrading to Ubuntu 24.04.

I did not test the GUI more than checking that it starts up without issues. If the pip version of wxPython is preferable, I can change that...

@echoix echoix changed the title docker: re-structure build stages for Ubuntu with and without GUI to optimze caching docker: re-structure build stages for Ubuntu with and without GUI to optimize caching Oct 22, 2025
@ninsbl ninsbl merged commit 9ba1976 into OSGeo:main Oct 23, 2025
31 checks passed
@echoix
Copy link
Member

echoix commented Oct 23, 2025

Backporting will be hard without the previous Dockerfile rewrite for 24.04 and building deps from source.

@ninsbl
Copy link
Member Author

ninsbl commented Oct 23, 2025

Backporting will be hard without the previous Dockerfile rewrite for 24.04 and building deps from source.

I see. I think I will make a "backport PR"...

@nilason
Copy link
Contributor

nilason commented Nov 18, 2025

@ninsbl Can we remove the "backport" label from this PR, if I understand correctly it was made with #6540?

@nilason nilason removed the backport to 8.4 PR needs to be backported to release branch 8.4 label Nov 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docker Docker related

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants