CodePipeline truncates folder names in output artifact S3 bucket

1

When configuring CodeBuild direct to source from and output to an S3 bucket, it can retain its whole project name in the output folder.

But if it's CodePipeline, the pipeline name is truncated to just 20 characters for the folder. This is probelmatic as we can have multiple applications in the same system/environment with their own pipelines, with a naming convention that can result in pretty long names well beyond twenty; the truncation essentially reduces them to the same name.

Why is this the case and how can CodePipeline be configured to avoid this behaviour?

icelava
asked 2 years ago672 views
1 Answer
0
Accepted Answer

A workaround is to use a unique set of characters for the 20 characters of pipeline names. This is to separate prefixes (folders) for the artifacts that are coming from separate pipelines, in case multiple pipelines have the same first 20 characters. However, the use of artifacts should not be affected by the current limitation (truncation) as CodePipeline uses a hash to determine artifacts. Please see below.

CodePipeline truncates artifact names, which can cause some bucket names to appear similar. Even though the artifact name appears to be truncated, CodePipeline maps to the artifact bucket in a way that is not affected by artifacts with truncated names. The pipeline can function normally. This is not an issue with the folder or artifacts. There is a 100-character limit to pipeline names. Although the artifact folder name might appear to be shortened, it is still unique for your pipeline.

AWS
Taka_M
answered 2 years ago
  • Thing is we're performing "extracurricular" activities beyond of the pipeline process. We reference back to the pipeline/output artifact folders to copy and deploy the secondary build artifacts. Don't think we have access to this hash set?

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions