{"id":18524548,"url":"https://github.com/stelligent/cfn-nag-pipeline","last_synced_at":"2025-04-09T12:30:55.182Z","repository":{"id":49223870,"uuid":"130234503","full_name":"stelligent/cfn-nag-pipeline","owner":"stelligent","description":"Lambda function to run cfn_nag in CodePipeline","archived":false,"fork":false,"pushed_at":"2021-06-22T21:59:24.000Z","size":60,"stargazers_count":11,"open_issues_count":1,"forks_count":7,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-24T05:34:25.378Z","etag":null,"topics":["cloudformation","codepipeline","serverless"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stelligent.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-19T15:14:34.000Z","updated_at":"2025-01-29T16:47:51.000Z","dependencies_parsed_at":"2022-08-19T01:31:23.682Z","dependency_job_id":null,"html_url":"https://github.com/stelligent/cfn-nag-pipeline","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stelligent%2Fcfn-nag-pipeline","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stelligent%2Fcfn-nag-pipeline/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stelligent%2Fcfn-nag-pipeline/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stelligent%2Fcfn-nag-pipeline/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stelligent","download_url":"https://codeload.github.com/stelligent/cfn-nag-pipeline/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248040088,"owners_count":21037813,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cloudformation","codepipeline","serverless"],"created_at":"2024-11-06T17:42:22.799Z","updated_at":"2025-04-09T12:30:52.877Z","avatar_url":"https://github.com/stelligent.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"![cfn_nag](https://github.com/stelligent/cfn_nag/raw/master/logo.png?raw=true \"cfn_nag\")\n\n## Overview\nA lambda function to run [cfn_nag](https://github.com/stelligent/cfn_nag) as an action in CodePipeline.\n\n## Installation\nTo install, navigate to the [cfn-nag-pipeline](https://serverlessrepo.aws.amazon.com/applications/us-east-1/275155842945/cfn-nag-pipeline) application in the AWS Serverless Repo (SAR) console and click deploy.\n\n### Custom Rules\nThe \"application\" deployed in SAR always reflects the latest version of cfn_nag published to [rubygems.org](https://rubygems.org/gems/cfn-nag).  This means the \"core\" rules should always be up to date.  That said, if you have developed custom rules, as of [0.5.5](https://github.com/stelligent/cfn_nag/releases/tag/v0.5.5) you can load those rules from an S3 bucket of your choosing.  At the point of deploying the \"application\" from SAR, you can select a rule bucket name and a prefix within that bucket.  Any objects with a key of the form: `prefix/\\*Rule.rb` will be loaded as a cfn_nag rule.\n\n## Reference the Lambda from AWS CodePipeline\n\n* Add a source step for a repository with CloudFormation templates\n* Add a downstream build step with provider `AWS Lambda`\n* Select the function name `cfn-nag-pipeline`\n* Select the glob for CloudFormation templates in the user parameters section for the step: e.g. `spec/test_templates/json/ec2_volume/*.json`\n* Select the name of the Input Artifact from the repository\n* For an example of such a pipeline, in this repository see: `spec/e2e/code_pipeline_using_nag.yml`\n\n## Development\n\n* Ensure **awscli** is installed. The credentials will need permission to create an S3 bucket, lambda functions, and an IAM role for the functions (at least)\n* To run tests and build the lambda function, run: `rake`\n* To deploy the function, run: `rake deploy`\n* [e2e_role.yml](./spec/e2e/e2e_role.yml) is necessary to run the release pipeline\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstelligent%2Fcfn-nag-pipeline","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstelligent%2Fcfn-nag-pipeline","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstelligent%2Fcfn-nag-pipeline/lists"}