Skip to content

Conversation

tcely
Copy link
Contributor

@tcely tcely commented Jan 17, 2025

  • Consolidate apk & apt commands
  • Consolidate ENV layers
  • Consolidate RUN layers
  • Remove unused variables
  • Remove packages that are no longer needed
  • Bind mount /app/Pipfile

/cache is now a tmpfs mount that has a cache mount on top for pipenv to use.

apt has cache mounts in the standard places:

  • /var/lib/apt
  • /var/cache/apt

This should significantly speed up the arm64 builds because two wheels were built on that architecture versus only one for amd64 builds.

- Consolidate apk & apt commands
- Consolidate ENV layers
- Consolidate RUN layers
- Remove unused variables
- Remove packages that are no longer needed
- Bind mount /app/Pipfile

`/cache` is now a `tmpfs` mount that has a `cache` mount on top for `pipenv` to use.

`apt` has `cache` mounts in the standard places:
- /var/lib/apt
- /var/cache/apt
@meeb
Copy link
Owner

meeb commented Jan 20, 2025

Thanks! Looks fine to me.

@meeb meeb merged commit cc5d221 into meeb:main Jan 20, 2025
@tcely tcely deleted the cache-apt-and-pipenv branch January 20, 2025 08:11
@tcely
Copy link
Contributor Author

tcely commented Jan 22, 2025

#74 132.0   Building wheel for libsass (setup.py): started
#74 1373.0   Building wheel for libsass (setup.py): finished with status 'done'
#74 1373.0 
#74 1373.1   Created wheel for libsass: filename=libsass-0.23.0-cp311-abi3-linux_aarch64.whl size=12880501 sha256=2313e5a93a91af40a4f318c6ab025e4502a3201fa7fe9352ae6ff99cb1c10f47
#74 1373.1 
#74 1373.1   Stored in directory: /cache/pipenv/wheels/a1/a1/53/148dc44ce1a0cfaee1213108605bea345e84e35cf7cc58ee21

That's about 21 minutes to build the libsass .whl (12.29 MiB) on arm64 that hopefully won't be in the next build of this stage.

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.

2 participants