Skip to content

Can't login to SSH or push. #635

@jomp16

Description

@jomp16
  • Gitea version (or commit ref): 1.0.0+109-ge5620f07 (commit e5620f0)
  • Git version: 2.11.0
  • Operating system: Arch Linux
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • Not relevant
  • Log gist:

Description

Application start with the command:

/usr/bin/gitea web --config /var/lib/gitea/custom/conf/app.ini --pid /var/lib/gitea/custom/run/app.pid

I can't login to SSH with gitea user.

ssh -v gitea@hostname gives the following error at the end:

2017/01/10 17:25:54 [...s/setting/setting.go:478 createPIDFile()] [E] Can't create PID folder on mkdir /usr/bin/custom: permission denied

In .ssh/authorized_keys has the lines:

command="/usr/bin/gitea serv key-2 --config='/var/lib/gitea/custom/conf/app.ini'",no-port-forwarding,no-X11-forwarding,no-agent-forwarding,no-pty ssh-rsa (and public key)

What I can guess it's gitea doesn't add --pid /var/lib/gitea/custom/run/app.pid to ssh file. Adding that small line to authorized_keys gives this error:

2017/01/10 17:33:20 [...tea.io/gitea/main.go:41 main()] [E] Fail to run app with [/usr/bin/gitea serv key-2 --config=/var/lib/gitea/custom/conf/app.ini -pid=/var/lib/gitea/custom/run/app.pid]: flag provided but not defined: -pid

So I don't know what it's going here.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions