You are not logged in.

#1 2025-12-31 10:13:12

hloth
Member
Registered: 2025-12-20
Posts: 2

Forgejo 13.0.3 issue with repo's systemd config / RUN_USER mismatch

https://archlinux.org/packages/extra/x86_64/forgejo/ is broken

It creates a "forgejo" system user, then creates systemd config and all the files using "forgejo" user. Then it pulls the latest app.ini example config from Forgejo's upstream repo: https://codeberg.org/forgejo/forgejo/sr … xample.ini which specifies RUN_USER = git

Which results in

2025/12/31 10:54:39 ...s/setting/setting.go:202:mustCurrentRunUserMatch() [F] Expect user 'git' but current user is: forgejo

If you change RUN_USER to forgejo, you have to login as forgejo@example.org instead of git@example.org which is kinda weird and also brings a lot of issues with git binary itself (at least for me). If you try ssh -T git@example.org you get

...s/setting/setting.go:202:mustCurrentRunUserMatch() [F] Expect user 'forgejo' but current user is: git

And if you change User and Group in systemd to git (according to the official binary installation docs: https://forgejo.org/docs/latest/admin/i … -git-user) then all the directories are unreadable for Forgejo. Also I guess separating git and forgejo users is a good idea since if someone gains unauthorized access to git user via exploit, they won't be able to read forgejo configs. But it doesn't work.

I can't post this to Arch Linux's package issues because their Gitlab is locked down. I asked to create an account for me via email but I just thought I'd share this here too, maybe I missed something.

Last edited by hloth (2025-12-31 10:14:33)

Offline

#2 2025-12-31 18:20:36

5hridhyan
Member
From: Asia
Registered: 2025-12-25
Posts: 640

Re: Forgejo 13.0.3 issue with repo's systemd config / RUN_USER mismatch

Has anyone tried adjusting the systemd User and directory permissions to match RUN_USER = git? I wonder if that works reliably without breaking Forgejo’s configs or SSH access.

Last edited by 5hridhyan (2025-12-31 19:52:48)


"Nothing matters" -a Nihilist
"Why bother thinking what matters?" -me

Online

#3 2026-01-02 14:16:11

hloth
Member
Registered: 2025-12-20
Posts: 2

Re: Forgejo 13.0.3 issue with repo's systemd config / RUN_USER mismatch

5hridhyan wrote:

Has anyone tried adjusting the systemd User and directory permissions to match RUN_USER = git? I wonder if that works reliably without breaking Forgejo’s configs or SSH access.


It does work but package needs fixing and all configs are created with forgejo:forgejo ownership

Offline

#4 2026-01-04 10:33:11

system72
Member
Registered: 2025-11-22
Posts: 572
Website

Re: Forgejo 13.0.3 issue with repo's systemd config / RUN_USER mismatch

Offline

Board footer

Powered by FluxBB