By using AWS re:Post, you agree to the Terms of Use

Questions tagged with AWS CodePipeline

Sort by most recent

Browse through the questions and answers listed below or filter and sort to narrow down your results.

1
answers
0
votes
4
views
asked 6 hours ago

AWS CodePipeline throwing error "Missing required parameter in pipeline.stages[0]: "name""

I am trying to create a CICD of my application that is available on Bitbucket. For this, I have created AWS CodePipeline that will deploy this app to ECS Cluster. I am trying to do this via AWS CLI. Here is my JSON file: ``` { "pipeline": { "roleArn": "arn:aws:iam::xxxxxxxxxxxx:role/service-role/AWSCodePipelineServiceRole-us-east-1-HubspotConnector", "stages": [{ "Name": "Source", "Actions": [{ "InputArtifacts": [], "ActionTypeId": { "Version": "1", "Owner": "AWS", "Category": "Source", "Provider": " " }, "OutputArtifacts": [{ "Name": "SourceArtifact" }], "RunOrder": 1, "Configuration": { "ConnectionArn": "arn:aws:codestar-connections:us-east-1:7xxxxxxxx3930:connection/5bxxxx2-257f-4xxxxx0-xxx3-edfdsfsdf7d672f", "FullRepositoryId": "rxxxxxh/hubspotcctorpipeline", "BranchName": "main", "OutputArtifactFormat": "CODE_ZIP" }, "Name": "ApplicationSource" }] }, { "name": "Build", "actions": [{ "inputArtifacts": [{ "name": "SourceArtifact" }], "name": "Build", "actionTypeId": { "category": "Build", "owner": "AWS", "version": "1", "provider": "CodeBuild" }, "outputArtifacts": [{ "name": "default" }], "Configuration": { "ProjectName": "cicdCli" }, "runOrder": 1 }] }, { "Name": "DeployECS", "ActionTypeId": { "Category": "Deploy", "Owner": "AWS", "Provider": "ECS", "Version": "1" }, "RunOrder": 2, "Configuration": { "ClusterName": "my-ecs-cluster", "ServiceName": "sample-app-service", "FileName": "imagedefinitions.json", "DeploymentTimeout": "15" }, "OutputArtifacts": [], "InputArtifacts": [{ "Name": "my-image" }] } ], "artifactStore": { "type": "S3", "location": "codepipeline-us-east-1-1xxx5xxxx29" }, "name": "newPipelineCicd", "version": 1 } } ``` Here is the error I am facing: ![Error](/media/postImages/original/IMevKWkplzTF6rf1ySM-KXmg) Can Someone describe me what I am doing wrong? I have searched for these errors but didn't get any help from anywhere. Also no one have written any tutorial or proper guide for this. I have found AWS documentation, one of the complexest documentations. Please guide me here.I would really appreciate that.
1
answers
0
votes
28
views
asked 12 days ago

Aws CodePipeline to Deploy to ECS Cluster using AWS CLI

I am using AWS CodePipeline to create a CICD. I am using Bitbucket as a source, using CodeBuid and Amazon CodePipeline. I have done this using console but now I want to create CodePipeline using AWS CLI. For this, we have to create a JSON file that holds the configuration. I want to deploy my application to ECS but I don't find any JSON format to do this. Here you can see the JSON file: ``` { "pipeline": { "roleArn": "arn:aws:iam::74555555530:role/service-role/AWSCodePipelineServiceRole-us-east-1-HubspotConnector", "stages": [ { "Name": "Source", "Actions": [ { "InputArtifacts": [], "ActionTypeId": { "Version": "1", "Owner": "AWS", "Category": "Source", "Provider": "CodeStarSourceConnection" }, "OutputArtifacts": [ { "Name": "SourceArtifact" } ], "RunOrder": 1, "Configuration": { "ConnectionArn": "arn:aws:codestar-connections:us-east-1:747926693930:connection/5b2xxxx2-2xxf-4xx0-9xx3-xxcfxxxxx72f", "FullRepositoryId": "an-c/rpipeline", "BranchName": "xxxxxx", "OutputArtifactFormat": "CODE_ZIP" }, "Name": "ApplicationSource" } ] }, { "name": "Build", "actions": [ { "inputArtifacts": [ { "name": "SourceArtifact" } ], "name": "Build", "actionTypeId": { "category": "Build", "owner": "AWS", "version": "1", "provider": "CodeBuild" }, "outputArtifacts": [ { "name": "default" } ], "configuration": { "ProjectName": "cicdCli" }, "runOrder": 1 } ] } ], "artifactStore": { "type": "S3", "location": "codepipeline-us-east-1-16896969692329" }, "name": "newPipelineCicd", "version": 1 } } ``` It has source stage, build stage but I don't know how to write build stage (for Deploy to ECS). Can someone guide me what are the exact parameters for build stage (ECS deployment).
1
answers
0
votes
47
views
asked 12 days ago