Questions tagged with AWS CodeCommit
Content language: English
Sort by most recent
Considerations when choosing codecommit or github?
I am building a new application using mostly serverless products (apig, lambda, dynamodb, code pipeline, etc..) and determining if I should use codecommit or github. I plan to leverage as much of the AWS ecosystem as possible, but are there features or limitations in either that need to be considered? This will be for a company that is growing fast, so the aws environment and code, functionality, will grow over time as well.
Restrict read access to CodeCommit Repository
Hello, I have 2 repositories[repo-1, repo-2] in my CodeCommit. And have 2 IAM groups[org-1, org-2], I want to create 2 IAM policies that will restrict read and write access for org-2 users in repo-1 and org-1 users in repo-2. I have successfully blocked the write access, now trying to block the read access, basically trying to implement two policies, where org-1 users won't be able to see repo-2 and vice versa. Can anyone please help me with this? Thanks in advance.
How am user from Cognito user pool can access a CodeCommit repository?
Hello, I have created a Cognito user pool with an identity pool, Identity pool has two attached IAM roles auth and unauth, auth has an IAM policy, which gives all Cognito permission as well as all CodeCommit permissions as well. Now when I add a user to the Cognito user pool, how that user can have access to a particular CodeCommit repository? Thanks in advance.
Email Subject for Email Customized for SNS Topic Email Endpoint without using Lambda
Have a business use case to be implemented without Lambda where a Email notification is sent to the subscribers of the SNS Topic with Customized Subject & Email Body when Code is pushed into the AWS CodeCommit repo. Scenario 1... For sending the notification solution, the AWS CodeCommit - Notify (Alert) - Manage Notifications - used where the end email recd. via Target SNS topic is HARD CORDED Email Subject & Email Body with details that couldn't be customized. Sample Email Subject: UPDATE: AWS CodeCommit ap-south-1 push: repository_name Sample Email body: Hello, The following repository in AWS CodeCommit has changed: <repository_name>. The repository was changed by the IAM user: username Branches: <branch_name>. The problem is with this soluton is, not able to customize either the subject or the Email Body. Scenario 2... For sending the notification solution, the AWS EventBridge - Rule - used with input transformer where the end email recd. via linked Target SNS topic. The Email Subject was Hard CODED as AWS Notification Message & Email Body got Fully Customized. Can can any one help what are workarounds that I can customize the Subject using EventBridge input transformation. NOTE: THE USE OF LAMBDA IS RESTRICTED TO IMPLEMENT THE REQUIREMENT
git clone not working when switch account
Hi team, I'm trying to clone a code commit repo `git clone https://xxxxx/v1/repos/myPrj` I have this error : `fatal: repository 'https://git - codecommit.xxxxxxx/v1/repos/myPrj/' not found` it works without issue for another repo in another account I can clone the repos of that account but when I switch to this account and try to git clone I have the above error, not sure why it works for one account and not for another. Thank you
Block read access to a branch in a CodeCommit Repository
I have created a repository in CodeCommit. It has one master branch and a few other branches such as module-1, module-2, module-3, module-4, and module-5. I have created 3 groups(org-1, org-2, org-3) and each group has 10 users. Now I am trying to figure out to achieve the following level of restriction. module-1 - org-1 users only - view and modify module-2 - org-2 users only - view and modify module-3 - org-3 users only - view and modify module-4 - org-1 users and org-2 users only - view and modify module-5 - all group users can access - read-only I am trying to enforce policies but can not achieve this. I can block write access successfully, but when it comes to blocking read access for a particular branch and making a branch invisible for a certain user group, cannot achieve that. Can you please help me with this scenario? Thanks in advance.
YAML_FILE_ERROR: mapping values are not allowed in this context at line 1
DOWNLOAD_SOURCE - YAML_FILE_ERROR: mapping values are not allowed in this context at line 1 Reference YAML file: buildspec.yaml version: 0.2 `phases: pre_build: commands: - echo Logging in to Amazon ECR... - $(aws ecr get-login --no-include-email --region $AWS_DEFAULT_REGION) build: commands: - echo Build started on `date` - echo Building the Docker image... - docker build -t web:1 . - docker tag web:1 020861552741.dkr.ecr.ap-southeast-1.amazonaws.com/hasib_cloud post_build: commands: - echo Build completed on `date` - echo Pushing the Docker image... - docker push 020861552741.dkr.ecr.ap-southeast-1.amazonaws.com/hasib_cloud ~ ![screenshot](/media/postImages/original/IMD8WJYdlxT_6k-v3PKRmBGA)
Not able to clone a codecommit repository
I followed these steps to get access to codecommit but i'm not able to clone repositories. 1. Install latest pip and git-remote-codecommit 2. Create and IAM user with policy AWSCodeCommitPowerUser and attach SSH and AWS Git credentials. 3. Configure the IAM user locally. I get the following error when try to clone through ssh: ``` Cloning into 'nfs-utils'... Enter passphrase for key '/home/risbhat/.ssh/id_rsa': no such identity: /home/risbhat/.ssh/id_ed25519: No such file or directory Permission denied (publickey). fatal: Could not read from remote repository. ``` I can see the repository exists and I have added the ssh keys/Git credentials to my IAM user. Am i missing some step?