I am getting the error Phase context status code during the AWS Code Pipeline Build Stage. COMMAND EXECUTION ERROR Message: npm ci command execution error. the departure status is 254
The deployment of new changes to the Code Commit Repository and the successful deployment of the Cloud Formation Stacks, similar to cdk deploy —all, are the desired results.
I adhered to the AWS tutorial. Everything is successfully deployed.
The Code Pipeline Stack:
export class CodePipelineStack extends Stack {
private readonly codePipeline: CodePipeline;
private readonly codeRepository : Repository;
constructor(scope: Construct, id: string, props: StackProps, context: CDKContext){
super(scope, id, props);
this.codeRepository = new Repository(this, "Repo-CDK", { repositoryName: "Repo-CDK", description: "Building A Repo using CDK Methodology" });
this.codePipeline = new CodePipeline(this, "pipeline", {
pipelineName: "pipeline",
selfMutation: true,
synth: new ShellStep('DeploymentStep', {
input: CodePipelineSource.codeCommit(this.codeRepository, environment),
commands: ['npm ci', 'npm run build', 'npx cdk synth'],
})
});
}
}
I also have app.synth(); at the bottom of the function that builds the stacks.