Skip to content

Streamline docker image build/distribution#3760

Merged
gazpachoking merged 10 commits intodevelopfrom
streamline-docker
May 8, 2023
Merged

Streamline docker image build/distribution#3760
gazpachoking merged 10 commits intodevelopfrom
streamline-docker

Conversation

@gazpachoking
Copy link
Copy Markdown
Member

@gazpachoking gazpachoking commented May 3, 2023

Motivation for changes:

Reduce build time and distribution size for updates to docker image. #3748
Alternate implementation to #3749

Detailed changes:

  • Optimize layers of docker images such that dep and webui layers don't need to be rebuilt/distributed when deps haven't changed
  • Add a cache to github actions so that reused docker layers don't need to be rebuilt. More testing is needed how much this helps. Hopefully a lot, because with the cross-arch building that step takes a full hour to do without caching.
  • Remove installation of cryptography library on builder image, which took a long time on multi-platform builds because it needed rust installed and to be compiled from scratch
  • Split release requirements from dev requirements (turns out this was sort of unrelated to docker)

Addressed issues/feature requests:

To Do:

  • Figure out if this actually does what I think it does and makes things better

@gazpachoking
Copy link
Copy Markdown
Member Author

Okay, latest changes eliminate the need for cryptography (which required rust and to be compiled on many platforms) and has reduced the full build time down from an hour to about 17 minutes. With the layer cache now being stored in github actions, full build should be rare, and normal builds much shorter.

@gazpachoking gazpachoking merged commit ff8714f into develop May 8, 2023
@gazpachoking gazpachoking deleted the streamline-docker branch January 14, 2025 01:41
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.

docker: reuse base docker image

1 participant