How to migrate from MF Gitlab to Forgejo
Find a file
2026-03-30 16:57:30 -04:00
forgejo_migration_assistant.png Migration Howto initial 2026-03-28 11:57:27 -04:00
gitlab_clone_url.png Migration Howto initial 2026-03-28 11:57:27 -04:00
README.md Note about key invalidation 2026-03-30 16:57:30 -04:00

Migration to Forgejo

Continue using GitLab until April 30th

Add the following config to your SSH config file (Typically ~/.ssh/config on Linux, safe to create if nonexistent.)

Until this is set, you will receive a key mismatch error.

Host git02.east1.us.mapleflask.net
    HostName git02.east1.us.mapleflask.net
    Port 222

Migrate

Please follow these steps to migrate your repos to Forgejo from Gitlab.

Once you begin the migration, you will NOT be able to pull or push any code until everyone finishes the migration and Subnet moves the endpoint.

In your SSH known_hosts file (typically ~/.ssh/known_hosts on Linux) remove any and all references to git01.east1.us.mapleflask.net. The host will be reused and if you used our old forge your system will reject the key of the new system unless this step is preformed.

  1. Obtain a Personal Access Token from Gitlab by visiting this link
    • Or by going to Preferences > Access > Personal Access Tokens
    • Click Add new token and give it a name
    • Provide the following scopes
      • read_user
      • read_repository
      • read_virtual_registry
      • read_api
      • api
  2. Save the generated key as you will need it for each repo migration
  3. Open the new forge and click the plus + button in the upper right of the page, then click New migration
  4. Select GitLab
  5. On the GitLab, copy the HTTPS URL.
    • Gitlab Clone URL
  6. Paste it into the migration page along with your PAT from step 1.
    • If you have LFS enabled on your repo, MAKE SURE to check the Migrate LFS files box. DO NOT change the advanced settings.
    • Forgejo Migration Assistant
  7. Click Migrate Repository and wait. DO NOT close or navigate away from the tab as the migration runs.

Switching to the new origin

ONLY DO THIS ONCE MIGRATION IS COMPLETE

To avoid needing to clone your entire repo again, follow these steps to change the origin server.

  1. Copy the SSH git URL of the repo you would like to move
  2. In your project on your PC, run the following command
    • git remote set-url origin <URL copied in step 1>
  3. Preform a pull to verify