The "Use hardened containers" section of the container hardening epic lists the pipelines that need to be updated to use hardened images. Here are the steps to complete each of those issues.
You will need:
- Find the pipeline in the Git repository the issue references. It will be named
pipeline.yml
. You may need to check the spreadsheet for reference. - Make a list of all resource types under
resource_types
and add checkboxes for them to the ticket. - Make a list of all built-in resource types used by
resources
in the pipeline, likes3
andgit
, and add checkboxes for them to the ticket.
- Add a resource type to the pipeline for
registry-image
that uses our customregistry-image-resource
image from ECR. It must be the first resource type under theresource_types
section. This way, it will override the built-inregistry-image
resource type. (See Resource Types, "resource_type schema", "source".)- Example code:
type: registry-image source: aws_access_key_id: ((ecr_aws_key)) aws_secret_access_key: ((ecr_aws_secret)) repository: registry-image-resource aws_region: us-gov-west-1 semver_constraint: ">= 1.0.0"
- Example code:
- Update each
resource_type
to use our hardened version. See the spreadsheet for details.- Change
type: docker-image
totype: registry-image
- Change
- Add a new new
resource_type
for each built-in type and use our custom, hardened images.