question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

AWS Amplify module with CodeCommit Repository

See original GitHub issue

❓ General Issue

The Question

Hello,

With the introduction of the Amplify constructors (App, Branch, Domain), I updated my code from CfnApp to App. I’m facing a problem with the accessToken and oauthToken parameters, they are now mandatory if you connect to a repository.

I understand this behavior when you connect to a 3rd party source provider like Github, Gitlab but what about the case of CodeCommit ? My deployment used to work with CfnApp connected to a CodeCommit repository and no token as parameters.

Best regards,

Environment

  • CDK CLI Version: 1.30.0
  • Module Version: 1.30.0
  • OS: OSX Catalina
  • Language: TypeScript

Other information

Related code from app.ts if (props.repository && !props.accessToken && !props.oauthToken) { throw new Error('EitheraccessTokenoroauthToken must be specified'); }

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
jogoldcommented, Mar 20, 2020

@MrArnoldPalmer we should maybe have something like a SourceCodeProvider class with static methods for the different providers. We can start with GitHub and CodeCommit.

0reactions
kinbaldcommented, Mar 20, 2020

Which accessToken? How did you generate it?

Seamed to our team that the only token that could be generated would be with HTTPS GitCredential manager in our IAM account. We used the password string as accessToken as a try.

Did you specify it in the 3 stacks?

Yes, they all use this role.

Do you have the full error message?

Sure : https://gist.github.com/kinbald/91d09f56830286b3fbc6cbadaf4161bd

Read more comments on GitHub >

github_iconTop Results From Across the Web

Getting started with existing code - AWS Amplify Hosting
Step 1: Connect a repository. Connect your GitHub, Bitbucket, GitLab, or AWS CodeCommit repository. You also have the option of manually uploading your...
Read more >
AWS::CodeCommit::Repository - AWS CloudFormation
Information about code to be committed to a repository after it is created in an AWS CloudFormation stack. Information about code is only...
Read more >
aws-cdk/aws-codecommit module - AWS Documentation
AWS CodeCommit is a version control service that enables you to privately store and manage Git repositories in the AWS cloud.
Read more >
Complete guide to full-stack CI/CD workflows with AWS Amplify
Complete guide to full-stack CI/CD workflows with AWS Amplify · Get started – zero config frontend deployments · Create an app backend with...
Read more >
Deploying a Static Website with AWS Amplify and CDK
Currently, CDK provides the option of using GitHub, GitLab and AWS CodeCommit as the source repository. For this example, CodeCommit is used as ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found