Draft
Conversation
Add support for S3-backed Docker build layer caching using BuildKit's type=s3 cache backend. This enables faster Docker builds by caching intermediate layers in S3. Configuration via environment variables: - LEEWAY_DOCKER_S3_CACHE_BUCKET: S3 bucket name (required) - LEEWAY_DOCKER_S3_CACHE_REGION: AWS region (required) - LEEWAY_DOCKER_S3_CACHE_PREFIX: Optional prefix for cache keys - LEEWAY_DOCKER_S3_CACHE_MODE: Cache mode (min/max, default: max) - LEEWAY_DOCKER_S3_CACHE_ENDPOINT: Custom S3 endpoint Also adds corresponding CLI flags for all options. When S3 cache is enabled, leeway automatically uses docker buildx build with --cache-from and --cache-to flags. Co-authored-by: Ona <no-reply@ona.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Add support for S3-backed Docker build layer caching using BuildKit's
type=s3cache backend. This enables faster Docker builds by caching intermediate layers in S3.New environment variables:
LEEWAY_DOCKER_S3_CACHE_BUCKET- S3 bucket name (required)LEEWAY_DOCKER_S3_CACHE_REGION- AWS region (required)LEEWAY_DOCKER_S3_CACHE_PREFIX- Optional prefix for cache keysLEEWAY_DOCKER_S3_CACHE_MODE- Cache mode:minormax(default:max)LEEWAY_DOCKER_S3_CACHE_ENDPOINT- Custom S3 endpoint for S3-compatible storageNew CLI flags:
--docker-s3-cache-bucket--docker-s3-cache-region--docker-s3-cache-prefix--docker-s3-cache-mode--docker-s3-cache-endpointWhen S3 cache is enabled, leeway automatically uses
docker buildx buildwith--cache-fromand--cache-toflags pointing to the configured S3 bucket.Related Issue(s)
Fixes CORE-
How to test
Requirements: