gitea: embedded subcommand not working in Linux

  • Gitea version (or commit ref): 1.12.1 (till latest)

Description

The embedded subcommand does not work list or extract any files.

Screenshots

bash-5.0# gitea -v
Gitea version 1.12.1 built with GNU Make 4.2.1, go1.14.4 : bindata, sqlite, sqlite_unlock_notify
bash-5.0# gitea embedded list '**'
bash-5.0#

Reason

Gitea embedded can not run with mismatched Linux user in an installed config, there will be no output at all.

Workaround

Run gitea with the correct Linux user (as in the app.ini), using su or sudo

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 3
  • Comments: 19 (12 by maintainers)

Commits related to this issue

Most upvoted comments

I found the root case of this bug.

  1. There is a check: https://github.com/go-gitea/gitea/blob/72f9050689912f5910a08d593ebe53078fe85aa4/modules/setting/setting.go#L954 . The code is pretty old (as early as 2014)
  2. The embedded command removes loggers: https://github.com/go-gitea/gitea/blob/72f9050689912f5910a08d593ebe53078fe85aa4/cmd/embedded.go#L115

Then bad thing happens: Gitea embedded can not run with mismatched Linux user in an installed config, and no error is outputted.

@lunny I think this is a bug, not related to docker. See my comments above. So maybe we should keep this open.