Last updated: March 20, 2026
Remote teams increasingly need collaboration features that AWS CodeCommit cannot fully provide. While CodeCommit served many organizations well, GitHub’s pull request workflows, Actions automation, and ecosystem integrations make it a stronger choice for distributed development teams. This guide walks through the migration process with practical commands and configuration examples you can apply immediately.
Table of Contents
- Why Remote Teams Choose GitHub Over CodeCommit
- Pre-Migration Preparation
- Migration Strategy: Mirror Git Repositories
- Updating Developer Workflows
- Handling AWS-Specific Integrations
- Preserving Code Review History
- Post-Migration Checklist
Why Remote Teams Choose GitHub Over CodeCommit
CodeCommit offers secure Git hosting within AWS, but remote teams often encounter friction with its limited collaboration features. GitHub provides code review tools, project management boards, and a marketplace of integrations that remote teams rely on for async communication.
The primary motivations for migration typically include: better pull request diffs and review tools, native CI/CD with GitHub Actions, simpler team permission management, and easier onboarding for developers familiar with GitHub’s interface. For teams spread across time zones, these features significantly reduce coordination overhead.
GitHub also provides native features that remote teams value highly. Required reviewers on protected branches ensure pull requests get reviewed before merging, even when the author and reviewer are in non-overlapping time zones. CODEOWNERS files route reviews automatically to the right people, eliminating the manual “who should review this?” overhead that costs remote teams real time every day.
CodeCommit’s approval rule templates cover some of this, but the configuration is less intuitive and requires IAM knowledge that front-end developers and designers on cross-functional teams may not have. GitHub’s interface is widely understood across roles, which reduces the tool-specific training burden for distributed teams.
Pre-Migration Preparation
Before executing the migration, audit your current CodeCommit repository structure and identify all branches, tags, and collaborators.
# List all CodeCommit repositories in your AWS account
aws codecommit list-repositories --region us-east-1
# Get repository details including branch information
aws codecommit get-repository --repository-name your-repo-name --region us-east-1
# List all branches in a repository
aws codecommit list-branches --repository-name your-repo-name --region us-east-1
Document your existing IAM users and their CodeCommit permissions. You’ll need to recreate these access configurations in GitHub, either through organization members, teams, or outside collaborators.
Also catalog any AWS services that trigger on CodeCommit events: SNS topics, Lambda functions, or EventBridge rules watching for push events. These integrations break silently if you migrate repositories without updating their source configuration.
Migration Strategy: Mirror Git Repositories
The most reliable migration method involves mirroring your entire Git history from CodeCommit to GitHub. This preserves all commits, branches, tags, and commit messages without losing history.
Step 1: Clone CodeCommit Repository Locally
First, configure Git to work with CodeCommit credentials. If you’re using AWS CLI v2, it handles authentication automatically with the default credential chain.
# Clone the CodeCommit repository with all branches
git clone https://git-codecommit.us-east-1.amazonaws.com/v1/repos/your-repo-name
cd your-repo-name
If you use git-remote-codecommit (GRC), install it first:
pip install git-remote-codecommit
# Clone using GRC format
git clone codecommit::us-east-1://your-repo-name
Step 2: Create GitHub Repository
Create your target repository on GitHub, either through the web interface or CLI:
# Using GitHub CLI (gh)
gh repo create your-org/your-repo-name --private --source=. --push
For private team repositories, adjust the visibility as needed. GitHub’s free organization tier includes unlimited collaborators on private repositories, a significant improvement over CodeCommit’s tiered pricing.
Step 3: Push All Branches and Tags
Push your entire repository history to GitHub:
# Add the new remote
git remote add github git@github.com:your-org/your-repo-name.git
# Push all branches
git push github --all
# Push all tags
git push github --tags
This approach preserves your complete Git history, including all branches that developers may have been working on. Verify the push completed successfully before proceeding.
For repositories with large binary files in Git history, consider running git filter-repo to remove them before migration. Migrating large blobs to GitHub can trigger LFS (Large File Storage) requirements or hit repository size limits.
Step 4: Configure Branch Protection
Recreate any branch protection rules you had in CodeCommit. GitHub’s branch protection settings provide more granular control:
# Set branch protection via GitHub CLI
gh api repos/your-org/your-repo-name/branches/main/protection \
--method PUT \
--field required_status_checks='{"strict":true,"contexts":["ci/tests"]}' \
--field enforce_admins=true \
--field required_pull_request_reviews='{"required_approving_review_count":1}'
Updating Developer Workflows
After migration, your team needs to update their local Git configurations. Provide clear documentation for developers to switch their remotes.
Developer Migration Script
Create a simple script your team can run:
#!/bin/bash
# migrate-remotes.sh
echo "Updating git remote from CodeCommit to GitHub..."
# Check current remotes
git remote -v
# Change the remote URL
git remote set-url origin git@github.com:your-org/your-repo-name.git
# Verify the change
git remote -v
# Fetch any remaining remote updates
git fetch origin
echo "Remote updated successfully!"
echo "Run 'git pull' to sync with the new remote."
Updating SSH Keys
CodeCommit uses AWS IAM-managed credentials or git-remote-codecommit. GitHub uses SSH keys or personal access tokens (PATs). Ensure developers configure their GitHub authentication before pushing:
# Test GitHub SSH connection
ssh -T git@github.com
# Configure git to use SSH for GitHub
git config --global url."git@github.com:".insteadOf "https://github.com/"
For organizations using SSO, GitHub’s SAML enforcement requires that personal access tokens and SSH keys be authorized for the organization before they work. Remind developers to authorize their keys at github.com/settings/keys after the migration completes.
Handling AWS-Specific Integrations
Many CodeCommit repositories integrate with AWS services. You’ll need to update these integrations to work with GitHub.
Updating CI/CD Pipelines
If you use AWS CodePipeline or CodeBuild, migrate to GitHub Actions or a similar CI/CD system:
# .github/workflows/ci.yml
name: CI
on:
push:
branches: [ main, develop ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Run tests
run: npm test
- name: Build
run: npm run build
For teams using AWS-specific tools like SAM or CDK, GitHub Actions can still deploy to AWS using OIDC federation, eliminating the need for long-lived AWS credentials:
- name: Configure AWS credentials via OIDC
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::123456789012:role/GitHubActionsDeployRole
aws-region: us-east-1
This is more secure than storing AWS access keys as GitHub secrets because the temporary credentials expire after the job completes.
Secrets Management Transition
CodeCommit users often store credentials in AWS Secrets Manager or Systems Manager Parameter Store. GitHub provides encrypted secrets at the repository or organization level:
# Add secrets via GitHub CLI
gh secret set AWS_ACCESS_KEY_ID --body "$AWS_ACCESS_KEY_ID"
gh secret set AWS_SECRET_ACCESS_KEY --body "$AWS_SECRET_ACCESS_KEY"
Organization-level secrets let you share credentials across multiple repositories without duplicating them. This matches the behavior teams were using with IAM roles across CodeCommit repositories.
Preserving Code Review History
One limitation of Git mirroring is that CodeCommit pull request comments and approvals don’t transfer automatically. Document any critical review decisions before migration:
# Export CodeCommit pull request comments (requires scripting)
aws codecommit get-pull-request --pull-request-id PR_ID --region us-east-1
Create a documentation page in your new GitHub repository summarizing any open review items that need attention after migration. For teams with extensive PR history, consider scripting an export to a Markdown file that becomes a permanent record in the repository.
Post-Migration Checklist
Verify the migration completed successfully with this verification process:
- Branch verification: Confirm all branches exist in GitHub
git ls-remote --heads github - Tag verification: Ensure all tags transferred
git ls-remote --tags github - Commit history: Spot-check commit counts match
# CodeCommit git rev-list --all --count # GitHub gh api repos/your-org/your-repo-name/stats/commit --jq '.[] | select(.total != null) | .total' -
Team access: Verify all developers can clone and push to the new repository
-
CI/CD status: Confirm automated tests and deployments function correctly
-
Webhook cleanup: Remove any remaining CodeCommit notification triggers in AWS to avoid confusion
- Repository archiving: Set the old CodeCommit repository to read-only (you cannot delete it immediately, but restricting push access prevents accidental dual-writes)
After two to four weeks of stable operation on GitHub, archive or delete the CodeCommit repository. Keeping both active longer than necessary leads to confusion about which remote is canonical.
Related Articles
- GitHub Projects vs Jira for a Remote Team of 3 Devs
- GitHub Actions Workflow for Remote Dev Teams
- Remote Work Tools: All Guides and Reviews
- CI/CD Pipeline Tools for a Remote Team of 2 Backend
- Generate weekly team activity report from GitHub Built by theluckystrike — More at zovo.one
Frequently Asked Questions
Who is this article written for?
This article is written for developers, technical professionals, and power users who want practical guidance. Whether you are evaluating options or implementing a solution, the information here focuses on real-world applicability rather than theoretical overviews.
How current is the information in this article?
We update articles regularly to reflect the latest changes. However, tools and platforms evolve quickly. Always verify specific feature availability and pricing directly on the official website before making purchasing decisions.
Does GitHub offer a free tier?
Most major tools offer some form of free tier or trial period. Check GitHub’s current pricing page for the latest free tier details, as these change frequently. Free tiers typically have usage limits that work for evaluation but may not be sufficient for daily professional use.
How do I get my team to adopt a new tool?
Start with a small pilot group of willing early adopters. Let them use it for 2-3 weeks, then gather their honest feedback. Address concerns before rolling out to the full team. Forced adoption without buy-in almost always fails.
What is the learning curve like?
Most tools discussed here can be used productively within a few hours. Mastering advanced features takes 1-2 weeks of regular use. Focus on the 20% of features that cover 80% of your needs first, then explore advanced capabilities as specific needs arise.