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

fix: removed changing ownership at the beginning of container start #218

Merged
merged 2 commits into from
Apr 5, 2024

Conversation

kylhuk
Copy link
Contributor

@kylhuk kylhuk commented Apr 4, 2024

Description

A chown of a download directory might lead to unwanted effects, as there are users who already have a working environment and want to switch to NZBGet. The chown is unnecessary, as the check if the necessary folders are existing and/or are writable happens somewhere else.

Here the issue to this PR: #217

Testing

Built the container in my environment and was able to run it successfully.

@luckedea
Copy link
Member

luckedea commented Apr 5, 2024

We can't remove chown completely here since it would break fresh docker installs.

@kylhuk
Copy link
Contributor Author

kylhuk commented Apr 5, 2024

We can't remove chown completely here since it would break fresh docker installs.

I disagree. The app could still run. In the WebUI you will then see error messages about some path issues. Additionally, I checked other, similar apps like sabnzbd, radarr and sonarr. No one is doing a chown while starting the docker container. So I think it would be good practice to move the permission problems to somewhere else, as currently you only support fresh installs, instead of supporting fresh and existing installs.

@luckedea
Copy link
Member

luckedea commented Apr 5, 2024

@kylhuk

I see your point.

We want to support all types of installs.

Other similar apps do have some sort of ownership/permissions checks too, it's not always a direct chown, and we have to do it - otherwise nzbget won't be able to work correctly with that folder.

Can you update your PR to only remove the -R please? I believe that should be the best compromise here.

@kylhuk
Copy link
Contributor Author

kylhuk commented Apr 5, 2024

@luckedea agreed, removed the -R for both chown, for /config and /downloads

@phnzb phnzb linked an issue Apr 5, 2024 that may be closed by this pull request
@phnzb
Copy link
Collaborator

phnzb commented Apr 5, 2024

@kylhuk
Thank you for contribution! Merged to develop.

@phnzb phnzb merged commit 36dad2f into nzbgetcom:develop Apr 5, 2024
1 check passed
@phnzb phnzb mentioned this pull request Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

chown issue in docker container
3 participants