aws / aws/aws-codebuild-docker-images

[CodeBuild] Skipping cache entry: path "/home/my-user/.gradle_home/caches/8.5" is not within allowed cache paths

Open
#821 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Dockerfile
Stars
1.2k
Forks
971
Avg merge
2h 47m
Merged PRs (30d)
1

Description

**Describe the bug**
Since May 19, 2026, build time of the components has raised significantly at CodeBuild (without any changes in buildspec.yaml).
Quick log analysis showed that some new log lines appeared:

```
[Container] 2026/05/19 19:04:11.296186 Expanded cache path /home/my-user/.gradle_home/caches/**/*
[Container] 2026/05/19 19:04:11.299145 Expanded cache path /home/my-user/.gradle_home/dependency-check-data/**/*
[Container] 2026/05/19 19:04:11.344842 Downloading S3 cache...
[Container] 2026/05/19 19:04:11.546731 Unarchiving cache...
[Container] 2026/05/19 19:04:11.608097 Skipping cache entry: path "/home/my-user/.gradle_home/caches/8.5" is not within allowed cache paths
[Container] 2026/05/19 19:04:11.608244 Skipping cache entry: path "/home/my-user/.gradle_home/caches/journal-1" is not within allowed cache paths
[Container] 2026/05/19 19:04:11.608287 Skipping cache entry: path "/home/my-user/.gradle_home/caches/jars-9" is not within allowed cache paths
[Container] 2026/05/19 19:04:11.608332 Skipping cache entry: path "/home/my-user/.gradle_home/caches/journal-1/journal-1.lock" is not within allowed cache paths
[Container] 2026/05/19 19:04:11.608599 Skipping cache entry: path "/home/my-user/.gradle_home/caches/journal-1/file-access.properties" is not within allowed cache paths
[Container] 2026/05/19 19:04:11.608645 Skipping cache entry: path "/home/my-user/.gradle_home/caches/journal-1/file-access.bin" is not within allowed cache paths
```

**To Reproduce**
buildspec.yaml:

```
cache:
paths:
- /home/my-user/.gradle_home/caches/**/*
- /home/my-user/.gradle_home/dependency-check-data/**/*

```

**Expected behavior**
caches from /home/my-user/.gradle_home/caches/ and /home/my-user/.gradle_home/dependency-check-data/ should be expanded normally as they used to before May 19, 2026

**Logs**
If applicable, add log output to help explain your problem.

**Platform (please complete the following information):**
aws/codebuild/amazonlinux2-x86_64-standard:5.0

**Additional context**
Add any other context about the problem here.

Contributor guide

Open the contributing guide

Research direction

Start with the buildspec.yaml cache paths and reproduce the reported behavior on aws/codebuild/amazonlinux2-x86_64-standard:5.0, using the log lines to trace why the expanded Gradle cache paths are rejected. Done means the caches under /home/my-user/.gradle_home/caches/ and dependency-check-data/ are accepted without the reported skipping messages.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, docker
Domain
build-system, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.