aws-codepipeline

Unable to load AWS credentials from any provider in the chain - Jenkins & AWS codepipeline

笑着哭i 提交于 2019-12-11 03:54:07
问题 Currently I'm trying to get Jenkins working with AWS codepipeline. I'm running Jenkins on a EC2 instance. However, for some reason, Jenkins fails to load the default credentials of AWS. I tried the following options: Initialize aws credentials with 'aws configure' command Use the aws-credentials plugin in Jenkins Perform export AWS_ACCESS_KEY_ID=.... and AWS_SECRET_ACCESS_KEY=.... in Jenkins cli Checked the ~/.aws/credentials file, if the credentials are present (which is the case) Followed

Code Build Access denied while downloading artifact from S3

只愿长相守 提交于 2019-12-11 00:37:45
问题 My CodeBuild is configured with CodePipeline. S3 is my artifact store. I continue to get an Access denied message despite having attached IAM roles with sufficient access. Screenshot of the error message I have already checked the service role associated with Codebuild. It has the following policy attached to it. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Resource": [ "arn:aws:logs:ap-southeast-1:682905754632:log-group:/aws/codebuild/Build", "arn:aws:logs:ap-southeast-1

Dynamically change branches on AWS CodePipeline

自古美人都是妖i 提交于 2019-12-10 10:47:16
问题 I am looking for a good solution on how to run parametrized (customized) builds in CodePipeline where branch can be changed dynamically? A little background on the problem: I need an on-demand environment that will be started on certain branch. We already use Bamboo CI server for part of the infrastructure and this is easily achievable with customized build also in Jenkins. So basically I need a way to trigger a build with branch as a variable on CodePipeline in AWS. 回答1: Currently

Terraform & AWS CodePipeline - Dynamically define actions on a stage

蹲街弑〆低调 提交于 2019-12-10 10:41:51
问题 I'm not sure if this is possible but thought I'd ask to check first. I have a CodePipeline defined in terraform , with a single Stage that has multiple actions. The Stage is pulling code from CodeCommit , and each action defines what repositories I want to use in the Pipeline . I'd like to create a variable that has a list of the CodeCommit repository names, and then dynamically create an action for each repository in that list. Is that possible with terraform ? I know you can use count to

CodePipeline: How to reference nested CloudFormation Stacks from GitHub as Source

旧街凉风 提交于 2019-12-09 13:11:00
问题 Our CloudFormation templates are stored in GitHub. Inside CodePipeline we're using GitHub as our Source, but we can't reference nested CloudFormation Stacks when they're not stored on S3. How can we reference CloudFormation nested Stacks when using GitHub as our source in CodePipeline? If this is not possible, how can we upload the CloudFormation Templates from GitHub to S3 between the Source Stage (from GitHub) and the Deploy Stage in CodePipeline? 回答1: There are two approaches I can think

Execute Terraform apply with AWS assume role

怎甘沉沦 提交于 2019-12-09 12:04:52
问题 I need to execute a Terraform template to provision infrastructure for an AWS account which I can access by assuming a role. The problem I have now is I do not have an IAM user in that AWS account so I do not have an aws_access_key_id or an aws_secret_access_key to set up another named profile in my ~/.aws/credentials . When I run command terraform apply , the template creates the infrastructure for my account, not the other account. How to run Terraform template using your account which has

Codepipeline restricting artifact properties in codebuild

半腔热情 提交于 2019-12-08 00:57:27
问题 I had created a codebuild to build my project based on the changes in codecommit. This is the batch-get-projects command details for it { "projects": [ { "name": "MultiRepBuild", "arn": "arn:aws:codebuild:us-east-1:100000xxx0x:project/MultiRepBui ld", "source": { "type": "CODECOMMIT", "location": "https://git-codecommit.us-east-1.amazonaws.com/v1/r epos/PythonRep", "gitCloneDepth": 1, "insecureSsl": false }, "secondarySources": [], "artifacts": { "type": "S3", "location": "testxxxthe

AWS CodePipeline doesn't work anymore - GitHub's token insufficient permissions

我怕爱的太早我们不能终老 提交于 2019-12-07 09:44:30
问题 I've created AWS Code Pipeline with GitHub as a source. It was working fine and I was able to fetch repository from GitHub without difficulties. I've deployed my app million times through this pipeline. Until last Sunday (15-11-2015) when I tried to release changes to my pipeline. Since then I'm getting Either the GitHub repository "epub" does not exist, or the GitHub access token provided has insufficient permissions to access the repository. Verify that the repository exists and edit the

How to add rollback functionality to a basic S3 CodeBuild deploy

此生再无相见时 提交于 2019-12-07 06:45:57
问题 I have followed this instruction to get a very basic ci workflow in aws. It works flawless but I want to have a extra functionality, rollback. First i though it would work "out-of-the-box", but not in my case, if I select the the previous job in CodeBuild that i want to rollback to and hit "Retry" i get this error message: "Error ArtifactsOverride must be set when using artifacts type CodePipelines". I have also tried to rerun the whole pipeline again with pipeline history page, but it's just

aws CAPABILITY_AUTO_EXPAND console web codepipeline with cloudformation

喜夏-厌秋 提交于 2019-12-06 02:10:26
问题 I am trying to complete a codepipeline with the cloudformation service and this error is generated. It must be said that the separate cloudformation service works well. The complete error is: JobFailed Requires capabilities: [CAPABILITY_AUTO_EXPAND] (Service: AmazonCloudFormation; Status Code: 400; Error Code: InsufficientCapabilitiesException; Request ID: 1a977102-f829-11e8-b5c6-f7cc8454c4d0) The solutions I have is to add the CAPABILITY_AUTO_EXPAND --capabilities parameter but that only