Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LFS files not deleted with repository #8423

Closed
2 tasks done
8ctopus opened this issue Oct 8, 2019 · 2 comments · Fixed by #8455
Closed
2 tasks done

LFS files not deleted with repository #8423

8ctopus opened this issue Oct 8, 2019 · 2 comments · Fixed by #8455
Labels
issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change
Milestone

Comments

@8ctopus
Copy link
Contributor

8ctopus commented Oct 8, 2019

  • Gitea version (or commit ref): 1.9.3
  • Git version: 2.17.1
  • Operating system: Ubuntu 18.04.3 LTS
  • Database (use [x]):
    • MySQL
  • Can you reproduce the bug at https://try.gitea.io:
    • Not relevant
  • Log gist:

How to reproduce:

  1. Clean installation of gitea 1.9.3 on Ubuntu with git LFS enabled and path set
ROOT = /home/gitea/gitea-repositories
LFS_START_SERVER = true
LFS_CONTENT_PATH = /home/gitea/data/lfs
  1. Create a new repository "repo" in gitea
  2. Clone the repository
git clone https://mydomain/gitea/company/repo.git
  1. Add LFS tracking and add a file to LFS
cd repo
git lfs track "*.zip"
cp ../file.zip .
git add .gitattributes file.zip
git commit -m "added: zip file LFS tracked"
git push origin master
  1. In gitea, delete the repository.
  2. On the server filesystem, the /home/gitea/data/lfs directory is not empty and still contains the zip file.
/home/gitea/data/lfs # ls -alRh
.:
total 12K
drwxr-xr-x 3 gitea gitea 4.0K Oct  8 07:20 .
drwxr-xr-x 3 gitea gitea 4.0K Oct  3 11:30 ..
drwxr-x--- 3 gitea gitea 4.0K Oct  8 07:20 31

./31:
total 12K
drwxr-x--- 3 gitea gitea 4.0K Oct  8 07:20 .
drwxr-xr-x 3 gitea gitea 4.0K Oct  8 07:20 ..
drwxr-x--- 2 gitea gitea 4.0K Oct  8 07:22 7e

./31/7e:
total 7.5M
drwxr-x--- 2 gitea gitea 4.0K Oct  8 07:22 .
drwxr-x--- 3 gitea gitea 4.0K Oct  8 07:20 ..
-rw-r----- 1 gitea gitea 7.5M Oct  8 07:21 ff4325718b51c0fabcd514539af2d1d6db8b8d458a2cc8a724d57d615bd8
@zeripath
Copy link
Contributor

Hmm this was previously fixed ... This must be a regression.

Is there an error in the logs on repository deletion?

@zeripath
Copy link
Contributor

Damn I think this is my fault. LFS files need to be deleted relative to the root of the content path.

#8455 should fix this.

@zeripath zeripath added the issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change label Oct 10, 2019
@lafriks lafriks added this to the 1.9.5 milestone Oct 11, 2019
@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change
Projects
None yet
3 participants