-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Installer fails to create directory when using docker #1221
Comments
You can specify any directory |
Sure, but the user doesn't know that /data isn't owned by git in a docker-environment and it might be inappropriate to just add another subfolder to /data/git oder /data/gitea. |
Why isn't there just an LFS directory by default? Enabling LFS doesn't do anything for people who don't use it, and it would no longer require the user to change this setting and possibly create a directory just to enable it. |
This could maybe fix simply fixed by adding "/data/lfs" to https://github.com/go-gitea/gitea/blob/master/docker/usr/bin/entrypoint#L3 and https://github.com/go-gitea/gitea/blob/master/docker/etc/s6/gitea/setup#L18 ? I can't test it right now but this should work. |
@sapk sounds like a splendid idea! However, the startup wizard should also be changed to have "/data/lfs" as a default path instead of an empty text field as of right now. Then people could simply launch with default settings and LFS would work out-of-the-box |
This seems be fixed some time and please feel free to reopen it. |
[x]
):Description
When using the docker image, the folder /data is owned by root (if using regular containers). Installing gitea now enables you to choose a folder for lfs, but if you input something like /data/lfs, the installation will fail with the following:
invalid_lfs_path%!(EXTRA *os.PathError=mkdir /data/lfs: permission denied)
Choosing one of the pre-existing directories and adding a subdirectory is fine (like /data/git/lfs), but it is unclear if that is advisable. Since the installer doesn't run as root, it can't create directories under /data. Maybe this can be fixed or clarified?
To solve this problem locally, I used created the directory /data/lfs and chown'd it to the user git manually and ran the installation.
Screenshots
The text was updated successfully, but these errors were encountered: