go-gitea / gitea

Git with a cup of tea! Painless self-hosted all-in-one software development service, including Git hosting, code review, team collaboration, package registry and CI/CD
https://gitea.com
MIT License
44.08k stars 5.41k forks source link

Migration from own gitlab not working #29224

Closed kimjohans closed 6 months ago

kimjohans commented 6 months ago

Description

gitea: OS: Linux Debian 12, up-to-date Installed as binary

Configuration added to app.ini:

[migration]
ALLOWED_DOMAINS = my-gitlab
BLOCKED_DOMAINS =
ALLOW_LOCALNETWORKS = true
SKIP_TLS_VERIFY = true

(restarted gitea service after each app.ini change)

Always the message "migrate.permission_denied_blocked": German "Du kannst von keinen nicht erlaubten Hosts importieren. Bitte fragen deinen Administrator, die Einstellungen ALLOWED_DOMAINS/ALLOW_LOCALNETWORKS/BLOCKED_DOMAINS zu überprüfen."

I also tried it with "git" migration (one of the other options in gitea), bit the result is the same.

grafik

The log file is not very helpful in the case:

2024/02/17 17:49:25 .../context_response.go:68:HTML() [D] Template: repo/migrate/gitlab
2024/02/17 17:49:25 ...eb/routing/logger.go:102:func1() [I] router: completed POST /repo/migrate for 192.168.1.175:51000, 200 OK in 16.4ms @ repo/migrate.go:151(repo.MigratePost)

Of course i tried to clone my gitlab repo again (to ensure, it is working): yes, working like always and cloned the repository to my computer.

Gitea Version

1.21.4 built with GNU Make 4.3, go1.21.5 : bindata, sqlite, sqlite_unlock_notify

Operating System

Linux Debian 12

How are you running Gitea?

Downloaded from gitea.io two hours ago

Database

MySQL/MariaDB

delvh commented 6 months ago

https://docs.gitea.com/administration/config-cheat-sheet#migrations-migrations

kimjohans commented 6 months ago

I used that URL to add the migration block to my app.ini. But there are also no details / infos for the migration

lunny commented 6 months ago

It's [migrations] not [migration].

kimjohans commented 6 months ago

Many thanks to lunny !

You know the feeling, when you try to find the error the whole day ... then a collegue looks over your should, pointing to a typo and that is the solution ?! Hmpf !!

Why is that block not automatically (by default) written in the app.ini ?

Can this ticket pls. can be switched into "enhancement" ? I think, i will not be the last idiot with that stupid mistake :)

lunny commented 6 months ago

Since there are hundreds of options, I don't think putting all options on the generated app.ini is a good idea. I think we can add a workaround label here and close it.

delvh commented 6 months ago

as per @lunny

github-actions[bot] commented 6 months ago

Automatically locked because of our CONTRIBUTING guidelines