[#PUP-778] PR (2086): Initial refactoring of yumrepo.

advertisement
[PUP-778] PR (2086): Initial refactoring of yumrepo. - apenney Created:
2013/11/18 Updated: 2014/11/07 Resolved: 2014/02/18
Status:
Project:
Component/s:
Affects
Version/s:
Fix Version/s:
Closed
Puppet
Community
None
Type:
Reporter:
Resolution:
Labels:
Remaining
Estimate:
Time Spent:
Original
Estimate:
Task
gepetto-bot
Fixed
github
Not Specified
Issue Links:
Relates
relates to PUP-1066 yum repos should be ensurable.
relates to PUP-789 Yumrepo should be refactored to use a...
Template:
Story Points:
Sprint:
PUP 3.5.0
Priority:
Assignee:
Votes:
Not Specified
Not Specified
Closed
Closed
customfield_10700 true
3
Week 2014-1-22 to 2014-1-29, Week 2014-1-29 to 2014-2-05, Week 20142-5 to 2014-2-12, Week 2014-2-12 to 2014-2-19
Description
Initial refactoring of yumrepo.





Normal
Unassigned
0
Author: Ashley Penney <[email protected]>
Company: Puppetlabs
Github ID: apenney
Pull Request 2086 Discussion
Pull Request 2086 File Diff
Pull Request Description
[I've made this PR early, as I'd like feedback on the direction of the provider/type, and the tests.
It seems to work for me, which is about as strongly tested as it is right now.]
This work strips out all of the provider code from the type, and
creates a new ruby provider for yumrepo.
While this code still uses inifile it's been rewritten to take advantage
of the modernization of Puppet. It's now a little easier to understand
and test.
(webhooks-id: 7bdd4552b53277247d47e57c305379d3)
Comments
Comment by gepetto-bot [ 2013/11/18 ]
puppetcla commented:
CLA signed by all contributors.
Comment by gepetto-bot [ 2013/11/27 ]
Sharpie commented:
Related tickets:
[Redmine 8758](http://projects.puppetlabs.com/issues/8758)
[Redmine 9293](http://projects.puppetlabs.com/issues/9293)
Comment by gepetto-bot [ 2013/11/27 ]
Sharpie commented:
Also incorporates [Redmine 22304](http://projects.puppetlabs.com/issues/22304)
Comment by gepetto-bot [ 2014/01/22 ]
unux commented:
@apenney from the yum config parser: http://yum.baseurl.org/gitweb?p=yum.git;a=blob;f=yum/config.py#l387
class BoolOption(Option):
"""An option representing a boolean value. The value can be one
of 0, 1, yes, no, true, or false.
"""
Seems like yum's boolean options also take yes and no in addition to (0|1|false|true). This might be worth expand
Comment by gepetto-bot [ 2014/01/22 ]
apenney commented:
Ahhhh, nice, I didn't look in config.py, I had only got as far as repo.py. That'll teach me. I'll fix this globally.
Comment by gepetto-bot [ 2014/01/24 ]
apenney commented:
Updated with all your comments (hopefully addressed).
On the PR message commits thing, I can only find 12687 that specifically addresses the request to delete things.
and add them in, I just don't know if I suck at searching.
Comment by gepetto-bot [ 2014/01/27 ]
apenney commented:
I'll keep working on this. I'll make sure self.reposdir is covered as well.
Comment by gepetto-bot [ 2014/01/28 ]
riton commented:
Hey, for #2268, you can now pull from 459933292 il you're okay with this.
Cheers
Comment by gepetto-bot [ 2014/01/29 ]
joshcooper commented:
@apenney I noticed that travis failed on commits 866f5c5 and 537b6f4. Could you fix those up? That way it's ea
Comment by gepetto-bot [ 2014/02/13 ]
Pull request Initial refactoring of yumrepo. has been closed.
Comment by gepetto-bot [ 2014/02/13 ]
adrienthebo commented:
Merged into master in e638972; this should be released in 3.5.0. Thanks for all your hard work!
Comment by gepetto-bot [ 2014/02/14 ]
adrienthebo commented:
I agree, I'll go though and do the needful shortly.
Comment by Kurt Wall [ 2014/02/18 ]
Verified in 3.4.2.909:
# pup-778.pp
yumrepo { 'repo-1' :
descr
=> 'PL repo for puppet at commit 06d5f532567618381db1900409ed29
baseurl =>
'http://builds.puppetlabs.lan/puppet/06d5f532567618381db1900409ed291d1723e
enabled => '1',
gpgcheck => '0',
ensure => 'present',
}
yumrepo { 'repo-2' :
descr
=> 'This repository does not exist',
baseurl => 'http://www.example.com',
enabled => '1',
gpgcheck => '1',
ensure => 'present',
}
# ls -1 /etc/yum.repos.d
CentOS-Base.repo
CentOS-Debuginfo.repo
CentOS-Media.repo
CentOS-Vault.repo
pl-puppet-06d5f532567618381db1900409ed291d1723e881-el-6-x86_64.repo
puppetlabs.repo
# puppet apply pup-778.pp
Notice: Compiled catalog for centos6-master.localdomain in environment pro
Notice: /Stage[main]/Main/Yumrepo[repo-2]/ensure: created
Notice: /Stage[main]/Main/Yumrepo[repo-1]/ensure: created
Notice: Finished catalog run in 0.09 seconds
# puppet resource yumrepo
[...]
yumrepo { 'repo-1':
ensure
=> 'present',
baseurl =>
'http://builds.puppetlabs.lan/puppet/06d5f532567618381db1900409ed291d1723e
descr
=> 'PL repo for puppet at commit 06d5f532567618381db1900409ed29
enabled => '1',
gpgcheck => '0',
}
yumrepo { 'repo-2':
ensure
=> 'present',
baseurl => 'http://www.example.com',
descr
=> 'This repository does not exist',
enabled => '1',
gpgcheck => '1',
}
[...]
Generated at Sat Mar 05 19:12:50 PST 2016 using JIRA 6.4.12#64027sha1:e3691cc1283c0f3cef6d65d3ea82d47743692b57.
Download
Random flashcards
Radiobiology

39 Cards

Pastoralists

20 Cards

Marketing

46 Cards

African nomads

18 Cards

History of Europe

27 Cards

Create flashcards