Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detect artifact name mismatch in CodePipeline deploy action TemplatePath #3125

Open
2 tasks
farski opened this issue Mar 29, 2024 · 0 comments
Open
2 tasks
Labels
enhancement New feature or request

Comments

@farski
Copy link

farski commented Mar 29, 2024

Is this feature request related to a new rule or cfn-lint capabilities?

rules

Describe the feature you'd like to request

Currently cfn-lint does not detect if the input artifact reference in a CodePipeline CloudFormation deploy action TemplatePath actually matches any of the provided InputArtifacts on the action.

The following example does not raise an error, even though the deploy will fail since SourceRepoArtifact and SourceArtifact do not match.

            - Name: My_Deploy_Action
              ActionTypeId:
                Category: Deploy
                Owner: AWS
                Provider: CloudFormationStackSet
                Version: "1"
              Configuration:
                StackSetName: My-StackSet
                Capabilities: CAPABILITY_IAM,CAPABILITY_AUTO_EXPAND
                Description: tktk
                TemplatePath: SourceRepoArtifact::src/template.yml # Does not match
                PermissionModel: SELF_MANAGED
                DeploymentTargets: !Ref AWS::AccountId
                Regions: us-east-1,us-east-2
                FailureTolerancePercentage: 0
                MaxConcurrentPercentage: 100
              InputArtifacts:
                - Name: SourceArtifact # Does not match
              RunOrder: 1

Describe the solution you'd like

Compare the available InputArtifacts of the deploy action and the artifact reference part of the TemplatePath and ensure that the value exists in both.

Additional context

No response

Is this something that you'd be interested in working on?

  • 👋 I may be able to implement this feature request

Would this feature include a breaking change?

  • ⚠️ This feature might incur a breaking change
@kddejong kddejong added the enhancement New feature or request label Mar 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants