Gitea root->rootless migration #13820

Closed
opened 2025-11-02 10:54:05 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @phoedos on GitHub (Dec 13, 2024).

Description

Please guide is it possible to make root->rootless docker image migration?
have a typical installation of gitea, like this:

services: 
  gitea:
    image: gitea/gitea:1.22.5
    restart: unless-stopped
    environment:
     ...
    volumes:
      - ./gitea_data:/data
    postges: 
...

if I change image to gitea/gitea:1.22.5-rootless and run the same compose, Gitea will show me a configuration screen (like on init setup) and out the error "existing gitea installation in present in DB"

Rootless container is more secure, Is it possible somehow to make a migration?

Gitea Version

1.22.5

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

docker

Database

PostgreSQL

Originally created by @phoedos on GitHub (Dec 13, 2024). ### Description Please guide is it possible to make root->rootless docker image migration? have a typical installation of gitea, like this: ``` services: gitea: image: gitea/gitea:1.22.5 restart: unless-stopped environment: ... volumes: - ./gitea_data:/data postges: ... ``` if I change image to gitea/gitea:1.22.5-rootless and run the same compose, Gitea will show me a configuration screen (like on init setup) and out the error "existing gitea installation in present in DB" Rootless container is more secure, Is it possible somehow to make a migration? ### Gitea Version 1.22.5 ### Can you reproduce the bug on the Gitea demo site? Yes ### Log Gist _No response_ ### Screenshots _No response_ ### Git Version _No response_ ### Operating System _No response_ ### How are you running Gitea? docker ### Database PostgreSQL
GiteaMirror added the issue/needs-feedback label 2025-11-02 10:54:05 -06:00
Author
Owner

@wxiaoguang commented on GitHub (Dec 13, 2024):

It is impossible to "auto" migrate because the directory structure is totally different , and the config is also different.

IMO the easiest approach might be:

  1. Start a new (empty) instance and adopt the repositories.
  2. Start a new (empty) instance, and try to import the database from the old instance, and try to move the directories to the proper place one by one manually.
@wxiaoguang commented on GitHub (Dec 13, 2024): It is impossible to "auto" migrate because the directory structure is totally different , and the config is also different. IMO the easiest approach might be: 1. Start a new (empty) instance and adopt the repositories. 2. Start a new (empty) instance, and try to import the database from the old instance, and try to move the directories to the proper place one by one manually.
Author
Owner

@GiteaBot commented on GitHub (Jan 12, 2025):

We close issues that need feedback from the author if there were no new comments for a month. 🍵

@GiteaBot commented on GitHub (Jan 12, 2025): We close issues that need feedback from the author if there were no new comments for a month. :tea:
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#13820