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

reposync: Implement --safe-write-path option (RhBug:1898089) #441

Merged
merged 1 commit into from
May 4, 2023

Conversation

m-blaha
Copy link
Member

@m-blaha m-blaha commented Oct 6, 2021

By default reposync is not allowed to write files outside of repository download path (by default ./). But there are some repositories that store packages using relative parent paths (e.g. ../packages-store/f/foo.rpm).
This patch introduces new --safe-write-path option that can override this limitation and set a root directory that is considered safe for writing.
For example dnf reposync --repoid=the_repo --safe-write-path=. will allow reposync to write files not only to ./the_repo directory but also to current working directory itself.

= changelog =
msg: With --safe-write-path option reposync can download repositories with relative package locations (like ../package-store/f/foo.rpm)
type: enhancement
resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1898089

@m-blaha m-blaha marked this pull request as ready for review October 8, 2021 07:11
@lukash lukash self-assigned this Oct 11, 2021
@m-blaha m-blaha marked this pull request as draft October 13, 2021 12:18
@lfarkas
Copy link

lfarkas commented Jun 13, 2022

it's working! +1 for move out of Draft!

@m-blaha m-blaha marked this pull request as ready for review July 21, 2022 14:48
@jan-kolarik jan-kolarik assigned jan-kolarik and unassigned lukash Mar 30, 2023
doc/reposync.rst Outdated Show resolved Hide resolved
By default reposync is not allowed to write files outside of repository
download path (by default ./<repo id>). But there are some repositories
that store packages using relative parent paths (e.g.
../packages-store/f/foo.rpm).
This patch introduces new --safe-write-path option that can override
this limitation and set a root directory that is considered safe for
writing.
For example `dnf reposync --repoid=the_repo --safe-write-path=.` will
allow reposync to write files not only to `./the_repo` directory but
also to current working directory itself.

= changelog =
msg: With --safe-write-path option reposync can download repositories with relative package locations (like ../package-store/f/foo.rpm)
type: enhancement
resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1898089
Copy link
Member

@jan-kolarik jan-kolarik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for also making the docs more comprehensible!

@jan-kolarik jan-kolarik merged commit 6cd5a10 into master May 4, 2023
@jan-kolarik jan-kolarik deleted the mblaha/reposync-relative branch May 4, 2023 14:42
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.

4 participants