500 error on deleting account #4056

Closed
opened 2025-11-02 05:35:55 -06:00 by GiteaMirror · 1 comment
Owner

Originally created by @bmerrison on GitHub (Oct 3, 2019).

Description

After deploying Gitea on a clean machine, with SSH and HTTPS disabled, we get a 500 error when a user attempts to delete their account. See the gist above for a syslog snippet from immediately after the request.

Attempting to delete the user from the admin page also fails, although it doesn't display a 500 error - just doesn't do anything.

After a bit of investigation we found that the user that Gitea is running as doesn't have a .ssh directory in their homedir. This causes the error [re-]generating authorized_keys seen at the end of the log. Creating the directory manually fixes the issue.

This has only become an issue since upgrading from 1.8.0 to 1.9.3. We wondered if the problem could be somehow related to the move away from sshkeygen here: https://github.com/go-gitea/gitea/pull/7128/files

Originally created by @bmerrison on GitHub (Oct 3, 2019). - Gitea version (or commit ref): 1.9.3 built with GNU Make 4.1, go1.12.9 : bindata, sqlite, sqlite_unlock_notify - Git version: 2.1.4 - Operating system: Debian Jessie - Database (use `[x]`): - [ ] PostgreSQL - [ ] MySQL - [ ] MSSQL - [x] SQLite - Can you reproduce the bug at https://try.gitea.io: - [ ] Yes (provide example URL) - [ ] No - [x] Not relevant - Log gist: https://gist.github.com/bmerrison/a8915f7f4a01a602c295546451f9488d ## Description After deploying Gitea on a clean machine, with SSH and HTTPS disabled, we get a 500 error when a user attempts to delete their account. See the gist above for a syslog snippet from immediately after the request. Attempting to delete the user from the admin page also fails, although it doesn't display a 500 error - just doesn't do anything. After a bit of investigation we found that the user that Gitea is running as doesn't have a `.ssh` directory in their homedir. This causes the error [re-]generating `authorized_keys` seen at the end of the log. Creating the directory manually fixes the issue. This has only become an issue since upgrading from 1.8.0 to 1.9.3. We wondered if the problem could be somehow related to the move away from sshkeygen here: https://github.com/go-gitea/gitea/pull/7128/files
GiteaMirror added the issue/regressiontype/bug labels 2025-11-02 05:35:55 -06:00
Author
Owner

@zeripath commented on GitHub (Oct 12, 2019):

I think you're right it's very likely secondary to that change and we should be just creating the directory if it doesn't exist.

@zeripath commented on GitHub (Oct 12, 2019): I think you're right it's very likely secondary to that change and we should be just creating the directory if it doesn't exist.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#4056