Reputation: 11
I setup a test artifactory server and downloaded some test rpms from a public mirror and then deployed these rpms through artifactory to a local artifactory yum repo (the whole point of this is to test artifactory w/ yum integration). So then I set everything else up and did a bunch of testing so generally speaking the environment has been shown to work (meaning artifactory.repo is config'd correctly and whatever else needed to be done). However. If I "yum install some.rpm" an rpm that is BOTH STORED LOCALLY IN MY ARTIFACTORY YUM REPO and ALSO AVAILABLE IN THE PUBLIC MIRRORS, yum will pull from the public mirror.
How do I deal with this? Should I deal with this? Or should I just let yum pull from the public mirror all the time and only use artifactory with yum for my company's rpms? I mean, what if I want to just build my own repo and not deal with the public mirrors in some cases...? Is there anything that can "preference" this stuff as opposed to just blowing away the public mirror repo config files in /etc/yum.repos.d/?
Upvotes: 1
Views: 898
Reputation: 2709
Well, it depends on your usecase.
By default Artifactory remote repositories also come with a local cache where they store all downloaded artifacts - so using a local repository to store the same artifacts is redundant.
You can config your yum client to pull from either the remote, local or both if you'd like - it has it's own internal ordering for which one it will access first.
You would mainly use a local repository for cases where you want to be 100% certain only specific versions are used in your build and don't want to rely on what the yum client will choose as an appropriate version, or for cases where you build your own packages for internal use and don't want anyone from 'outside' (outside the team/company whatever) having access to them.
Upvotes: 1