{"action":"created","issue":{"url":"https://api.github.com/repos/RexOps/Rex/issues/546","labels_url":"https://api.github.com/repos/RexOps/Rex/issues/546/labels{/name}","comments_url":"https://api.github.com/repos/RexOps/Rex/issues/546/comments","events_url":"https://api.github.com/repos/RexOps/Rex/issues/546/events","html_url":"https://github.com/RexOps/Rex/pull/546","id":56140896,"number":546,"title":"Ensure update_system always updates package repositories first","user":{"login":"abeverley","id":4589486,"avatar_url":"https://avatars.githubusercontent.com/u/4589486?v=3","gravatar_id":"","url":"https://api.github.com/users/abeverley","html_url":"https://github.com/abeverley","followers_url":"https://api.github.com/users/abeverley/followers","following_url":"https://api.github.com/users/abeverley/following{/other_user}","gists_url":"https://api.github.com/users/abeverley/gists{/gist_id}","starred_url":"https://api.github.com/users/abeverley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abeverley/subscriptions","organizations_url":"https://api.github.com/users/abeverley/orgs","repos_url":"https://api.github.com/users/abeverley/repos","events_url":"https://api.github.com/users/abeverley/events{/privacy}","received_events_url":"https://api.github.com/users/abeverley/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"krimdomu","id":388436,"avatar_url":"https://avatars.githubusercontent.com/u/388436?v=3","gravatar_id":"","url":"https://api.github.com/users/krimdomu","html_url":"https://github.com/krimdomu","followers_url":"https://api.github.com/users/krimdomu/followers","following_url":"https://api.github.com/users/krimdomu/following{/other_user}","gists_url":"https://api.github.com/users/krimdomu/gists{/gist_id}","starred_url":"https://api.github.com/users/krimdomu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krimdomu/subscriptions","organizations_url":"https://api.github.com/users/krimdomu/orgs","repos_url":"https://api.github.com/users/krimdomu/repos","events_url":"https://api.github.com/users/krimdomu/events{/privacy}","received_events_url":"https://api.github.com/users/krimdomu/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/RexOps/Rex/milestones/13","labels_url":"https://api.github.com/repos/RexOps/Rex/milestones/13/labels","id":299513,"number":13,"title":"backlog","description":"These are task that should be done","creator":{"login":"krimdomu","id":388436,"avatar_url":"https://avatars.githubusercontent.com/u/388436?v=3","gravatar_id":"","url":"https://api.github.com/users/krimdomu","html_url":"https://github.com/krimdomu","followers_url":"https://api.github.com/users/krimdomu/followers","following_url":"https://api.github.com/users/krimdomu/following{/other_user}","gists_url":"https://api.github.com/users/krimdomu/gists{/gist_id}","starred_url":"https://api.github.com/users/krimdomu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krimdomu/subscriptions","organizations_url":"https://api.github.com/users/krimdomu/orgs","repos_url":"https://api.github.com/users/krimdomu/repos","events_url":"https://api.github.com/users/krimdomu/events{/privacy}","received_events_url":"https://api.github.com/users/krimdomu/received_events","type":"User","site_admin":false},"open_issues":24,"closed_issues":1,"state":"open","created_at":"2013-03-30T07:59:54Z","updated_at":"2015-02-03T22:23:20Z","due_on":null,"closed_at":null},"comments":14,"created_at":"2015-01-31T21:47:56Z","updated_at":"2015-02-04T01:11:40Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/RexOps/Rex/pulls/546","html_url":"https://github.com/RexOps/Rex/pull/546","diff_url":"https://github.com/RexOps/Rex/pull/546.diff","patch_url":"https://github.com/RexOps/Rex/pull/546.patch"},"body":"There is a mixture of behaviours with update_system. With some operating systems it will update the package repository cache first, with others it won't. This patch attempts to make the behaviour consistent, and always update repositories first, given that this is most likely what one would want to do when updating a system.\r\n\r\nDisclaimer: I have only experience with apt, but have attempted to cover all operating systems."},"comment":{"url":"https://api.github.com/repos/RexOps/Rex/issues/comments/72771552","html_url":"https://github.com/RexOps/Rex/pull/546#issuecomment-72771552","issue_url":"https://api.github.com/repos/RexOps/Rex/issues/546","id":72771552,"user":{"login":"ferki","id":3117609,"avatar_url":"https://avatars.githubusercontent.com/u/3117609?v=3","gravatar_id":"","url":"https://api.github.com/users/ferki","html_url":"https://github.com/ferki","followers_url":"https://api.github.com/users/ferki/followers","following_url":"https://api.github.com/users/ferki/following{/other_user}","gists_url":"https://api.github.com/users/ferki/gists{/gist_id}","starred_url":"https://api.github.com/users/ferki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ferki/subscriptions","organizations_url":"https://api.github.com/users/ferki/orgs","repos_url":"https://api.github.com/users/ferki/repos","events_url":"https://api.github.com/users/ferki/events{/privacy}","received_events_url":"https://api.github.com/users/ferki/received_events","type":"User","site_admin":false},"created_at":"2015-02-04T01:11:40Z","updated_at":"2015-02-04T01:11:40Z","body":"I also think that I should just shut up, get some sleep and read all the docs before I write stuff, instead of doing it off the top of my head :) `yum update` does seem to upgrade the package metadata and then install available upgrades (though it might be needed to `yum makecache` before and/or `yum clean metadata` to make sure that it does not use cached information?).\r\n\r\nThe main principles remain the same though:\r\n1. don't force a specific distro's way of doing things onto other distros ~~ \"do what makes sense on the given distro\"\r\n2. the same rex function call should do equivalent operations on different distros\r\n\r\nWe can definitely improve the current situation in various ways, but I'm not 100% sure if we can resolve all conflicts in this case - so what we can't resolve, we should carefully document, along with the description of the problem, the chosen and/or the alternative solutions, and possibly the arguments pro and contra for those solutions."}}