Hi. I self-host gitea in docker and have a few repos, users, keys, etc. I installed forgejo in docker and it runs, so I stopped the container and copied /var/lib/docker/volumes/gitea_data/_data/* to /var/lib/docker/volumes/forgejo_data/_data/, but when I restart the forgejo container, forgejo doesn’t show any of my repos, users, keys, etc.

My understanding was the the current version of forgejo is a drop-in replacement for gitea, so I was hoping all gitea resources were saved to its docker volume and would thus be instantly usable by forgejo. Guess not. :(

Does anyone have any experience migrating their gitea instance to forgejo?

  • catloafEnglish
    arrow-up
    5
    arrow-down
    1
    ·
    7 months ago
    link
    fedilink

    That’s essentially what they did.

    • poVoqEnglish
      arrow-up
      4
      arrow-down
      0
      ·
      7 months ago
      link
      fedilink

      You have a very loose definition of “essentially”. I can see easily see multiple ways of the OP’s copy approach failing while swapping out the container in place would not.

      • Mike WooskeyOPEnglish
        arrow-up
        1
        arrow-down
        0
        ·
        7 months ago
        link
        fedilink

        Can you share some of them so I might have an idea what to try to do differently?

        • poVoqEnglish
          arrow-up
          2
          arrow-down
          0
          ·
          7 months ago
          link
          fedilink

          You need to share more details about your setup, but as others have already mentioned, it could be an database issue, because usually Gitea is configured to use a Postgresql database.

          Also make sure you don’t combine an upgrade with a migration, the Gitea and Forgejo versions need to be roughly the same. Especially around the 1.20 version there was a need to change the folder structure before upgrading.

          • Mike WooskeyOPEnglish
            arrow-up
            1
            arrow-down
            0
            ·
            7 months ago
            link
            fedilink

            Thanks for that info. I did combine an upgrade (1.20 to 1.21) with the migrations, but I guess I lucked into it working. My problem was that the container’s path to the migrated gitea volume was incorrect.

    • Mike WooskeyOPEnglish
      arrow-up
      3
      arrow-down
      0
      ·
      7 months ago
      link
      fedilink

      That is what I did. And it didn’t work.