Skip to content

S3 Express does not work with RoleARN

I have deployed a GitLab Runner on EKS and configured distributed caching using AWS S3 Express One Zone. However, the runner is unable to retrieve the cache from S3 Express One Zone.

Here is my configuration

[runners.cache]
Type = "s3"
Shared = true
[runners.cache.s3]
BucketName = "<BUCKET>--aps1-az1--x-s3"
BucketLocation = "ap-south-1"
RoleARN = "arn:aws:iam::<ACCOUNT_ID>:role/gitlab-runner-iam-role"
DualStack = false
ServerAddress = "s3express-aps1-az1.ap-south-1.amazonaws.com"
AuthenticationType = "iam"

During pipeline execution, I encounter the following error:

WARNING: blob (key "project/44/p1-non_protected") (code=Unknown): operation error S3: HeadObject, get identity: get credentials: operation error S3: CreateSession, https response error StatusCode: 403, RequestID: 01b0e6766c00019472dc8588001396fcaa81266, HostID: 5qNCJAKp1oUUbu6FN, api error AccessDenied: Access Denied 
Failed to extract cache

Even though I am using S3 Express, it appears that the runner is attempting to use the standard S3 client instead of the S3 Express client. Am I missing any configuration?