)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":13252,"name":"Dr. Jens Harbott","display_name":"Jens Harbott (frickler)","email":"frickler@offenerstapel.de","username":"jrosenboom"},"change_message_id":"7c5343ef5281eb8517acc46693021e8c4b8f9566","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Parameterize cirros image list"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Image list shouldn\u0027t be hardcoded, otherwise Infra\u0027s jobs will always cache"},{"line_number":10,"context_line":"them even they are not actually used."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I73455940b50c1123fd0dc2bba592c5bbf977d52a"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"da6895a0_cae2819f","line":10,"updated":"2016-10-21 06:18:01.000000000","message":"I don\u0027t see why a bit more caching will be bad, can you be more explicit here?","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"c9756a83f81bdc5b671c28d4ef110c94df8bea1d","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Parameterize cirros image list"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Image list shouldn\u0027t be hardcoded, otherwise Infra\u0027s jobs will always cache"},{"line_number":10,"context_line":"them even they are not actually used."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I73455940b50c1123fd0dc2bba592c5bbf977d52a"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"da6895a0_e194c8e9","line":10,"in_reply_to":"da6895a0_c1b6e43c","updated":"2016-10-21 09:08:13.000000000","message":"Done","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"c512dd1e566833bbfe6b8af2de6781e0471660ae","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Parameterize cirros image list"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Image list shouldn\u0027t be hardcoded, otherwise Infra\u0027s jobs will always cache"},{"line_number":10,"context_line":"them even they are not actually used."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I73455940b50c1123fd0dc2bba592c5bbf977d52a"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"da6895a0_fbd71921","line":10,"in_reply_to":"da6895a0_cae2819f","updated":"2016-10-21 07:52:05.000000000","message":"For my understanding, no images *need* to be cached by default. If some are really needed, they can be explicitly cached using this tool.","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"88006b479e856163111ea23bf2cbb85cc2b7f98a","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Parameterize cirros image list"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Image list shouldn\u0027t be hardcoded, otherwise Infra\u0027s jobs will always cache"},{"line_number":10,"context_line":"them even they are not actually used."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I73455940b50c1123fd0dc2bba592c5bbf977d52a"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"da6895a0_c1b6e43c","line":10,"in_reply_to":"da6895a0_fbd71921","updated":"2016-10-21 08:46:26.000000000","message":"We should point out in the commit message that some of the images used by devstack are quite large, so only using the ones that are actually used by the environment you\u0027re caching images for is very helpful.\n\nopenvz\u0027s image is 125MB","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"}],"doc/source/configuration.rst":[{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"1950cc78fa3c31de71dc7a852588d8bc1bd243b7","unresolved":false,"context_lines":[{"line_number":501,"context_line":"drivers will be cached, although not all of them are needed and may take"},{"line_number":502,"context_line":"considerable time to download. So it is recommended to overwrite with"},{"line_number":503,"context_line":"what you really need."},{"line_number":504,"context_line":""},{"line_number":505,"context_line":"Instance Type"},{"line_number":506,"context_line":"-------------"},{"line_number":507,"context_line":""}],"source_content_type":"text/x-rst","patch_set":6,"id":"da6895a0_9159595d","line":504,"updated":"2016-10-24 23:14:04.000000000","message":"I feel like it would be nice to be more general and more specific at the same time\n\nSomething like\n\n---\n\nThe tools/image_list.sh script is provided to help with pre-caching images.  Running this script will by default provide URLS to download all images for all drivers; the list can be pruned for particular situations (see the --list option for available drivers).\n\nIn openstack-ci, test-images are cached during the build of CI images.  See project-config:nodepool/elements/cache-devstack/extra-data.d/55-cache-devstack-repos\n\n---","commit_id":"0265f49960f1f5ae6f553ba881b2aa1db1bb07fa"}],"stackrc":[{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"aa8ff48e223aff8050ee3d417b8203c8ee69fb87","unresolved":false,"context_lines":[{"line_number":630,"context_line":"# Specify possible virt drivers to tools/image_list.sh script to help with"},{"line_number":631,"context_line":"# pre-caching images. Please always keep dummy in the end position to trigger"},{"line_number":632,"context_line":"# the fall through case."},{"line_number":633,"context_line":"DEVSTACK_SUPPORTED_VIRT_DRIVERS\u003d\"openvz ironic libvirt vsphere xenserver dummy\""},{"line_number":634,"context_line":""},{"line_number":635,"context_line":"CIRROS_VERSION\u003d${CIRROS_VERSION:-\"0.3.4\"}"},{"line_number":636,"context_line":"CIRROS_ARCH\u003d${CIRROS_ARCH:-\"x86_64\"}"}],"source_content_type":"application/x-shellscript","patch_set":7,"id":"da6895a0_3469448c","line":633,"updated":"2016-10-25 22:57:34.000000000","message":"so can we get rid of \"dummy\"?  it seems like we should just iterate over this","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"c07813c70d3a96387f529543b518af3ba9a7d073","unresolved":false,"context_lines":[{"line_number":630,"context_line":"# Specify possible virt drivers to tools/image_list.sh script to help with"},{"line_number":631,"context_line":"# pre-caching images. Please always keep dummy in the end position to trigger"},{"line_number":632,"context_line":"# the fall through case."},{"line_number":633,"context_line":"DEVSTACK_SUPPORTED_VIRT_DRIVERS\u003d\"openvz ironic libvirt vsphere xenserver dummy\""},{"line_number":634,"context_line":""},{"line_number":635,"context_line":"CIRROS_VERSION\u003d${CIRROS_VERSION:-\"0.3.4\"}"},{"line_number":636,"context_line":"CIRROS_ARCH\u003d${CIRROS_ARCH:-\"x86_64\"}"}],"source_content_type":"application/x-shellscript","patch_set":11,"id":"ba5da102_0fa46ba4","line":633,"updated":"2016-10-28 00:57:32.000000000","message":"Let\u0027s get rid of this \"dummy\" sentinel value.  There\u0027s the idea of a \"fake\" virt-driver that is a real thing for scalability testing.  fake and dummy are basically synonymous in this context so it\u0027s quite confusing.","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"f742e783a0a16ebf229983ddcc87d1096132b190","unresolved":false,"context_lines":[{"line_number":630,"context_line":"# Specify possible virt drivers to tools/image_list.sh script to help with"},{"line_number":631,"context_line":"# pre-caching images. Please always keep dummy in the end position to trigger"},{"line_number":632,"context_line":"# the fall through case."},{"line_number":633,"context_line":"DEVSTACK_SUPPORTED_VIRT_DRIVERS\u003d\"openvz ironic libvirt vsphere xenserver dummy\""},{"line_number":634,"context_line":""},{"line_number":635,"context_line":"CIRROS_VERSION\u003d${CIRROS_VERSION:-\"0.3.4\"}"},{"line_number":636,"context_line":"CIRROS_ARCH\u003d${CIRROS_ARCH:-\"x86_64\"}"}],"source_content_type":"application/x-shellscript","patch_set":11,"id":"ba5da102_356dfc98","line":633,"in_reply_to":"ba5da102_0fa46ba4","updated":"2016-10-28 05:47:27.000000000","message":"Done","commit_id":"8b75646f7860e55767307c4200b473364df862c0"}],"tools/image_list.sh":[{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"b27584b07977590259fa4f1f89c79f0f433ea2a8","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":38,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":39,"context_line":"if [[ \"$num\" -lt 5 ]]; then"},{"line_number":40,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":41,"context_line":"    exit 1"},{"line_number":42,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":1,"id":"5a8bc5a2_f9a4c94b","line":39,"updated":"2016-09-27 02:54:08.000000000","message":"should the num at here be impacted also?","commit_id":"57248277826f489f9d3e033239885d666fc64a41"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"1e33ea6862a014ec90c67f7b0cc2b1f3d4881828","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":38,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":39,"context_line":"if [[ \"$num\" -lt 5 ]]; then"},{"line_number":40,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":41,"context_line":"    exit 1"},{"line_number":42,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":1,"id":"5a8bc5a2_51af1694","line":39,"in_reply_to":"5a8bc5a2_f9a4c94b","updated":"2016-09-28 01:56:09.000000000","message":"Done","commit_id":"57248277826f489f9d3e033239885d666fc64a41"},{"author":{"_account_id":970,"name":"Dean Troyer","email":"dtroyer@gmail.com","username":"dtroyer"},"change_message_id":"ab012cb1bfabcd4223a9048f5b19f9535d4e86fe","unresolved":false,"context_lines":[{"line_number":13,"context_line":""},{"line_number":14,"context_line":"# Possible virt drivers, if we have more, add them here. Always keep"},{"line_number":15,"context_line":"# dummy in the end position to trigger the fall through case."},{"line_number":16,"context_line":"DRIVERS\u003d${@:-\"openvz ironic libvirt vsphere xenserver dummy\"}"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"# Extra variables to trigger getting additional images."},{"line_number":19,"context_line":"export ENABLED_SERVICES\u003d\"h-api,tr-api\""}],"source_content_type":"text/x-sh","patch_set":2,"id":"3a98d1f4_ca5da27a","line":16,"updated":"2016-09-30 19:14:45.000000000","message":"Maybe not now, but eventually this list of drivers needs to move elsewhere.  This tool should not know what the possibilities are.  Adding a deprecation warning here would be polite but it is likely to get lost in the noise of these logs.","commit_id":"8f2a643949c618e82fe3ff855ed6832228bb1b0b"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"f074011b8a464b46611678528dbf94ceab8a87bb","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":38,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":39,"context_line":"if [[ \"$num\" -lt 3 ]]; then"},{"line_number":40,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":41,"context_line":"    exit 1"},{"line_number":42,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":2,"id":"3a98d1f4_2a375cb1","line":39,"updated":"2016-09-29 02:19:06.000000000","message":"Depending on the purpose of this checking. But it may be better to calculate the number basing on the driver list?","commit_id":"8f2a643949c618e82fe3ff855ed6832228bb1b0b"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"32439075cd94f6b5d330068002ce2bad048ac098","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":38,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":39,"context_line":"if [[ \"$num\" -lt 3 ]]; then"},{"line_number":40,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":41,"context_line":"    exit 1"},{"line_number":42,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":2,"id":"3a98d1f4_dc17944f","line":39,"in_reply_to":"3a98d1f4_2a375cb1","updated":"2016-09-29 09:54:43.000000000","message":"The number being 5 seems to be a bit of a hack in the first place - it was just a guess of how many images we should have if we\u0027re listing images for all drivers.\n\nI think that requiring a minimum of 3 images to be cached is possibly OK, but it\u0027s annoying that there is this hard-coded value.","commit_id":"8f2a643949c618e82fe3ff855ed6832228bb1b0b"},{"author":{"_account_id":970,"name":"Dean Troyer","email":"dtroyer@gmail.com","username":"dtroyer"},"change_message_id":"ab012cb1bfabcd4223a9048f5b19f9535d4e86fe","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":38,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":39,"context_line":"if [[ \"$num\" -lt 3 ]]; then"},{"line_number":40,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":41,"context_line":"    exit 1"},{"line_number":42,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":2,"id":"3a98d1f4_ea6fbe28","line":39,"in_reply_to":"3a98d1f4_dc17944f","updated":"2016-09-30 19:14:45.000000000","message":"This is a sanity check, I\u0027m not sure why sdague picked 5 originally, but at this point I\u0027d say just check for an empty list in preparation for removing the list of defaults in line 16.  That will make debugging the breakage caused by that much simpler later.","commit_id":"8f2a643949c618e82fe3ff855ed6832228bb1b0b"},{"author":{"_account_id":13252,"name":"Dr. Jens Harbott","display_name":"Jens Harbott (frickler)","email":"frickler@offenerstapel.de","username":"jrosenboom"},"change_message_id":"7c5343ef5281eb8517acc46693021e8c4b8f9566","unresolved":false,"context_lines":[{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"if [[ -z $@ ]]; then"},{"line_number":15,"context_line":"    echo \"WARNING: The default drivers are deprecated although they \\"},{"line_number":16,"context_line":"might still work for now. It is highly recommended to specify the \\"},{"line_number":17,"context_line":"drivers as parameters.\""},{"line_number":18,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":3,"id":"da6895a0_0acc7934","line":15,"updated":"2016-10-21 06:18:01.000000000","message":"I think this warning should include a more detailed reference about where it is generated, \"default drivers\" is pretty ambivalent in the context of devstack as a whole.","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"c512dd1e566833bbfe6b8af2de6781e0471660ae","unresolved":false,"context_lines":[{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"if [[ -z $@ ]]; then"},{"line_number":15,"context_line":"    echo \"WARNING: The default drivers are deprecated although they \\"},{"line_number":16,"context_line":"might still work for now. It is highly recommended to specify the \\"},{"line_number":17,"context_line":"drivers as parameters.\""},{"line_number":18,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":3,"id":"da6895a0_5bce4584","line":15,"in_reply_to":"da6895a0_0acc7934","updated":"2016-10-21 07:52:05.000000000","message":"Indeed. I will just explicitly show what the original defaults are.","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"},{"author":{"_account_id":13252,"name":"Dr. Jens Harbott","display_name":"Jens Harbott (frickler)","email":"frickler@offenerstapel.de","username":"jrosenboom"},"change_message_id":"7c5343ef5281eb8517acc46693021e8c4b8f9566","unresolved":false,"context_lines":[{"line_number":42,"context_line":""},{"line_number":43,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":44,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":45,"context_line":"if [[ \"$num\" -lt 0 ]]; then"},{"line_number":46,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":47,"context_line":"    exit 1"},{"line_number":48,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":3,"id":"da6895a0_8a6a4919","line":45,"updated":"2016-10-21 06:18:01.000000000","message":"How could num \u003c 0 ever happen? Seems you should rather remove this sanity check completely now.","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"c512dd1e566833bbfe6b8af2de6781e0471660ae","unresolved":false,"context_lines":[{"line_number":42,"context_line":""},{"line_number":43,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":44,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":45,"context_line":"if [[ \"$num\" -lt 0 ]]; then"},{"line_number":46,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":47,"context_line":"    exit 1"},{"line_number":48,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":3,"id":"da6895a0_7bcb0973","line":45,"in_reply_to":"da6895a0_8a6a4919","updated":"2016-10-21 07:52:05.000000000","message":"Done. My bad. It makes more sense to remove the sanity check completely.","commit_id":"f28c23e93002e230e66837758440af2ffb9940e1"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"e3d2ddb12a9aedf7d246bbca54f94fcdea7f5a4b","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":38,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":39,"context_line":"if [[ \"$num\" -lt 5 ]]; then"},{"line_number":40,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":41,"context_line":"    exit 1"},{"line_number":42,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":4,"id":"da6895a0_013c5c92","side":"PARENT","line":39,"updated":"2016-10-21 08:49:35.000000000","message":"The sanity check is still needed - but we should make sure if we are trying to cache images then we should end up with at least 1.","commit_id":"201c01f19b855aec3521c206fc0add5a01940c4b"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"1950cc78fa3c31de71dc7a852588d8bc1bd243b7","unresolved":false,"context_lines":[{"line_number":13,"context_line":""},{"line_number":14,"context_line":"# Possible virt drivers, if we have more, add them here. Always keep"},{"line_number":15,"context_line":"# dummy in the end position to trigger the fall through case."},{"line_number":16,"context_line":"DRIVERS\u003d${@:-\"openvz ironic libvirt vsphere xenserver dummy\"}"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"# Extra variables to trigger getting additional images."},{"line_number":19,"context_line":"export ENABLED_SERVICES\u003d\"h-api,tr-api\""}],"source_content_type":"text/x-sh","patch_set":6,"id":"da6895a0_1145496f","line":16,"updated":"2016-10-24 23:14:04.000000000","message":"So this has come up here and in the other project-config review, about keeping this in sync.\n\nAfter thinking on it, I\u0027m coming to the conclusion the best idea is probably to keep this list in just one place, and that place seems to be stackrc \n\nmy thought is that we add to stackrc, near the current IMAGE_URLS bit, this list in something called like DEVSTACK_SUPPORTED_VIRT_DRIVERS\n\nwe can then use that list here and as long as stackrc is updated, we will get the images too.  stackrc can have a big comment about how this hangs together.\n\nFor this script, it should be quite easy to make this use getopt so that it can take a \"--list\" argument and echo this list, and then an operator can clearly see their options\n\none other thought is that maybe it could have an \"--excludes\" option, that takes known ones *out* of the list, but leaves everything else.  that way, if a new image comes in, we get it by default.","commit_id":"0265f49960f1f5ae6f553ba881b2aa1db1bb07fa"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"397178f021a7bdea8ead8d991f39006549062f83","unresolved":false,"context_lines":[{"line_number":13,"context_line":""},{"line_number":14,"context_line":"# Possible virt drivers, if we have more, add them here. Always keep"},{"line_number":15,"context_line":"# dummy in the end position to trigger the fall through case."},{"line_number":16,"context_line":"DRIVERS\u003d${@:-\"openvz ironic libvirt vsphere xenserver dummy\"}"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"# Extra variables to trigger getting additional images."},{"line_number":19,"context_line":"export ENABLED_SERVICES\u003d\"h-api,tr-api\""}],"source_content_type":"text/x-sh","patch_set":6,"id":"da6895a0_69004c02","line":16,"in_reply_to":"da6895a0_1145496f","updated":"2016-10-25 13:30:29.000000000","message":"So the way I was thinking this should work is we want each CI to be able to specify which IMAGES it needs to be cached.  In the general case there is no value in caching the openvz image, even for infra, since it\u0027s not tested anywhere.\n\nThe downloads from 3rd party websites for untested drivers also adds risks if image build failure (which is where we got frustrated with this first, in our CI loop)\n\nIs your suggestion here to effectively keep the current behaviour (i.e. caching the un-used and large openvz image) unless someone explicitly adds DEVSTACK_SUPPORT_VIRT_DRIVERS in their local.conf for their CI loop?","commit_id":"0265f49960f1f5ae6f553ba881b2aa1db1bb07fa"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"437c979076a02353e68a3829212e24f22795b441","unresolved":false,"context_lines":[{"line_number":13,"context_line":""},{"line_number":14,"context_line":"# Possible virt drivers, if we have more, add them here. Always keep"},{"line_number":15,"context_line":"# dummy in the end position to trigger the fall through case."},{"line_number":16,"context_line":"DRIVERS\u003d${@:-\"openvz ironic libvirt vsphere xenserver dummy\"}"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"# Extra variables to trigger getting additional images."},{"line_number":19,"context_line":"export ENABLED_SERVICES\u003d\"h-api,tr-api\""}],"source_content_type":"text/x-sh","patch_set":6,"id":"da6895a0_b4455418","line":16,"in_reply_to":"da6895a0_69004c02","updated":"2016-10-25 22:27:44.000000000","message":"I\u0027m onboard with being able to cull the list for the reasons you mentioned\n\njust there was some concern around keeping image_list.sh updated as changes happen to virt drivers. \n\nusers wouldn\u0027t touch DEVSTACK_SUPPORT_VIRT_DRIVERS or whatever we call it.  It would be the canonical global list of drivers to choose from, which we can iterate over and present as a list of options in the image_list.sh script.","commit_id":"0265f49960f1f5ae6f553ba881b2aa1db1bb07fa"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"2b8ec9b5d673f5d309706bc113d0fdd314f3ed26","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_293654e6","line":14,"updated":"2016-10-25 13:35:50.000000000","message":"Does this really work?\nOPTS isn\u0027t ever read, and getopt isn\u0027t called in the loop below?","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"d382d222f04d89709ac6a5bea4ce3f9521ee90cd","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_faa093a1","line":14,"in_reply_to":"da6895a0_14ca806d","updated":"2016-10-26 06:02:36.000000000","message":"Done","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"d382d222f04d89709ac6a5bea4ce3f9521ee90cd","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_ba961b4a","line":14,"in_reply_to":"da6895a0_293654e6","updated":"2016-10-26 06:02:36.000000000","message":"It really works.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"db01fa8f835bcbdcf26d81ae1d273a3ce73eb0dd","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_6bc83c23","line":14,"in_reply_to":"da6895a0_293654e6","updated":"2016-10-25 18:15:12.000000000","message":"maybe you missed something like \"eval set -- \"$OPTS\"\"?\nAnd you can refer to \"tools/xen/scripts/install-os-vpx.sh\" to get opts.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"d382d222f04d89709ac6a5bea4ce3f9521ee90cd","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_9a9dd75b","line":14,"in_reply_to":"da6895a0_6bc83c23","updated":"2016-10-26 06:02:36.000000000","message":"getopts isn\u0027t getopt.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"aa8ff48e223aff8050ee3d417b8203c8ee69fb87","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_14ca806d","line":14,"in_reply_to":"da6895a0_6bc83c23","updated":"2016-10-25 22:57:34.000000000","message":"style nit, use $(","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"2b8ec9b5d673f5d309706bc113d0fdd314f3ed26","unresolved":false,"context_lines":[{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"},{"line_number":18,"context_line":"  case \"$1\" in"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_294d746c","line":15,"updated":"2016-10-25 13:35:50.000000000","message":"I\u0027m not sure I like this - I guess it implies that we must be able to override DEVSTACK_SUPPORTED_VIRT_DRIVERS in a CI loops\u0027 localrc/local.conf?\n\nWithout a way to specify what images we want, we could easily be caching things that are never teste dby the CI.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"aa8ff48e223aff8050ee3d417b8203c8ee69fb87","unresolved":false,"context_lines":[{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d`getopt -o hl --long help,list,exclude: -- \"$@\"`"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"},{"line_number":18,"context_line":"  case \"$1\" in"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_d4fac8bc","line":15,"in_reply_to":"da6895a0_294d746c","updated":"2016-10-25 22:57:34.000000000","message":"I\u0027m not thinking that the user ever touches DEVSTACK_SUPPORTED_VIRT_DRIVERS?  That is just the canonical list of drivers which this script supports and it\u0027s kept next to where we setup IMAGE_URLS for clarity.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"54408760e08fe71afc28dbff41a007ea202ca66e","unresolved":false,"context_lines":[{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"},{"line_number":18,"context_line":"  case \"$1\" in"},{"line_number":19,"context_line":"    -l | --list ) echo \"$DRIVERS\" | tr \u0027 \u0027 \u0027\\n\u0027 | sort | uniq ; exit 0 ;;"},{"line_number":20,"context_line":"    --exclude ) shift ; EXCLUSION\u003d\"$@\"; break ;;"},{"line_number":21,"context_line":"    -h | --help ) echo -e \""},{"line_number":22,"context_line":"Show pre-caching image urls"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_ab6ed4fe","line":19,"updated":"2016-10-25 18:18:14.000000000","message":"why sort them? It says the dummy should be the last one.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"01597cf0a7f877a350f81d280e2fb9b1613aca41","unresolved":false,"context_lines":[{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"},{"line_number":18,"context_line":"  case \"$1\" in"},{"line_number":19,"context_line":"    -l | --list ) echo \"$DRIVERS\" | tr \u0027 \u0027 \u0027\\n\u0027 | sort | uniq ; exit 0 ;;"},{"line_number":20,"context_line":"    --exclude ) shift ; EXCLUSION\u003d\"$@\"; break ;;"},{"line_number":21,"context_line":"    -h | --help ) echo -e \""},{"line_number":22,"context_line":"Show pre-caching image urls"}],"source_content_type":"text/x-sh","patch_set":7,"id":"ba5da102_18a305a0","line":19,"in_reply_to":"da6895a0_1aef07b1","updated":"2016-10-26 06:31:24.000000000","message":"understood. But I meant that it had broken the statement saying \"Always keeping dummy in the end\". I known it won\u0027t break the function at here as it just print list to stdout. But possibly mislead the users.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"d382d222f04d89709ac6a5bea4ce3f9521ee90cd","unresolved":false,"context_lines":[{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"},{"line_number":18,"context_line":"  case \"$1\" in"},{"line_number":19,"context_line":"    -l | --list ) echo \"$DRIVERS\" | tr \u0027 \u0027 \u0027\\n\u0027 | sort | uniq ; exit 0 ;;"},{"line_number":20,"context_line":"    --exclude ) shift ; EXCLUSION\u003d\"$@\"; break ;;"},{"line_number":21,"context_line":"    -h | --help ) echo -e \""},{"line_number":22,"context_line":"Show pre-caching image urls"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_1aef07b1","line":19,"in_reply_to":"da6895a0_ab6ed4fe","updated":"2016-10-26 06:02:36.000000000","message":"sort is the prerequisite for uniq","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"db01fa8f835bcbdcf26d81ae1d273a3ce73eb0dd","unresolved":false,"context_lines":[{"line_number":27,"context_line":"Options:"},{"line_number":28,"context_line":" -h, --help \\t A brief usage guide"},{"line_number":29,"context_line":" -l, --list \\t List available drivers"},{"line_number":30,"context_line":" --exclude \u003cexclusions\u003e \\t Show image urls excluding specified drivers"},{"line_number":31,"context_line":"\"; exit 0 ;;"},{"line_number":32,"context_line":"    * ) break ;;"},{"line_number":33,"context_line":"  esac"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_6bde7c12","line":30,"updated":"2016-10-25 18:15:12.000000000","message":"why not give a shorten option for exclude also?","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"01597cf0a7f877a350f81d280e2fb9b1613aca41","unresolved":false,"context_lines":[{"line_number":27,"context_line":"Options:"},{"line_number":28,"context_line":" -h, --help \\t A brief usage guide"},{"line_number":29,"context_line":" -l, --list \\t List available drivers"},{"line_number":30,"context_line":" --exclude \u003cexclusions\u003e \\t Show image urls excluding specified drivers"},{"line_number":31,"context_line":"\"; exit 0 ;;"},{"line_number":32,"context_line":"    * ) break ;;"},{"line_number":33,"context_line":"  esac"}],"source_content_type":"text/x-sh","patch_set":7,"id":"ba5da102_78aa4172","line":30,"in_reply_to":"da6895a0_5a2fbff5","updated":"2016-10-26 06:31:24.000000000","message":"Please ignore it:-) That\u0027s just a question as others all have a shorten option. But yes, that\u0027s a needed for this case.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"d382d222f04d89709ac6a5bea4ce3f9521ee90cd","unresolved":false,"context_lines":[{"line_number":27,"context_line":"Options:"},{"line_number":28,"context_line":" -h, --help \\t A brief usage guide"},{"line_number":29,"context_line":" -l, --list \\t List available drivers"},{"line_number":30,"context_line":" --exclude \u003cexclusions\u003e \\t Show image urls excluding specified drivers"},{"line_number":31,"context_line":"\"; exit 0 ;;"},{"line_number":32,"context_line":"    * ) break ;;"},{"line_number":33,"context_line":"  esac"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_5a2fbff5","line":30,"in_reply_to":"da6895a0_6bde7c12","updated":"2016-10-26 06:02:36.000000000","message":"Why do?","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"2b8ec9b5d673f5d309706bc113d0fdd314f3ed26","unresolved":false,"context_lines":[{"line_number":42,"context_line":"ALL_IMAGES\u003d\"\""},{"line_number":43,"context_line":"for driver in $DRIVERS; do"},{"line_number":44,"context_line":"    VIRT_DRIVER\u003d$driver"},{"line_number":45,"context_line":"\tif [[ \" $EXCLUSION \" \u003d\u003d *\" $VIRT_DRIVER \"* ]]; then"},{"line_number":46,"context_line":"\t    continue"},{"line_number":47,"context_line":"\tfi"},{"line_number":48,"context_line":"    URLS\u003d$(source $TOP_DIR/stackrc \u0026\u0026 echo $IMAGE_URLS)"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_4931c8eb","line":45,"updated":"2016-10-25 13:35:50.000000000","message":"Tabs","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"d382d222f04d89709ac6a5bea4ce3f9521ee90cd","unresolved":false,"context_lines":[{"line_number":42,"context_line":"ALL_IMAGES\u003d\"\""},{"line_number":43,"context_line":"for driver in $DRIVERS; do"},{"line_number":44,"context_line":"    VIRT_DRIVER\u003d$driver"},{"line_number":45,"context_line":"\tif [[ \" $EXCLUSION \" \u003d\u003d *\" $VIRT_DRIVER \"* ]]; then"},{"line_number":46,"context_line":"\t    continue"},{"line_number":47,"context_line":"\tfi"},{"line_number":48,"context_line":"    URLS\u003d$(source $TOP_DIR/stackrc \u0026\u0026 echo $IMAGE_URLS)"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_9a395744","line":45,"in_reply_to":"da6895a0_4931c8eb","updated":"2016-10-26 06:02:36.000000000","message":"Done","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"db01fa8f835bcbdcf26d81ae1d273a3ce73eb0dd","unresolved":false,"context_lines":[{"line_number":57,"context_line":""},{"line_number":58,"context_line":"# Sanity check - ensure we have a minimum number of images"},{"line_number":59,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":60,"context_line":"if [[ -n $DRIVERS \u0026\u0026 \"$num\" -lt 1 ]]; then"},{"line_number":61,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":62,"context_line":"    exit 1"},{"line_number":63,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_2b9564dd","line":60,"updated":"2016-10-25 18:15:12.000000000","message":"Suggest calculate the number basing on the target image list which has excluded the ones with --exclude.","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"aa8ff48e223aff8050ee3d417b8203c8ee69fb87","unresolved":false,"context_lines":[{"line_number":59,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":60,"context_line":"if [[ -n $DRIVERS \u0026\u0026 \"$num\" -lt 1 ]]; then"},{"line_number":61,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":62,"context_line":"    exit 1"},{"line_number":63,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_f4918c53","line":62,"updated":"2016-10-25 22:57:34.000000000","message":"i\u0027m not sure this is really helpful any more?","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"d382d222f04d89709ac6a5bea4ce3f9521ee90cd","unresolved":false,"context_lines":[{"line_number":59,"context_line":"num\u003d$(echo $ALL_IMAGES | tr \u0027,\u0027 \u0027\\n\u0027 | sort | uniq | wc -l)"},{"line_number":60,"context_line":"if [[ -n $DRIVERS \u0026\u0026 \"$num\" -lt 1 ]]; then"},{"line_number":61,"context_line":"    echo \"ERROR: We only found $num images in $ALL_IMAGES, which can\u0027t be right.\""},{"line_number":62,"context_line":"    exit 1"},{"line_number":63,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":7,"id":"da6895a0_da3bcf36","line":62,"in_reply_to":"da6895a0_f4918c53","updated":"2016-10-26 06:02:36.000000000","message":"Done","commit_id":"fb4e8b56b2058fa16e9c862cfd396970e685a63e"},{"author":{"_account_id":17920,"name":"Jianghua Wang","email":"jianghua.wang@citrix.com","username":"wjhfresh"},"change_message_id":"0609a35ce8029a19aefca0f4b977222d19cf43df","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d$(getopt -o hl --long help,list,exclude: -- \"$@\")"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":9,"id":"ba5da102_589f3d5f","line":14,"updated":"2016-10-26 06:24:35.000000000","message":"ok. Now I understand that here seems to validate args by using getopt but don\u0027t use the value parse from getopt. It should work for this case. But suggest use either getopt or just the lines from line17-34 which can validate the options too.","commit_id":"05c5d2c2b1e2cff69d8ce9748be8c028d2f79f83"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"c5739a9fba13a9c3c61d1e330dca5f7dfca79be1","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d$(getopt -o hl --long help,list,exclude: -- \"$@\")"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_d7377ae1","line":14,"updated":"2016-10-27 10:34:45.000000000","message":"I don\u0027t like what seems to be non-standard use of getopt.  See install_prereqs or unstack or our install-os-vpx scripts in devstack for standard usage of getopt.\n\nIt\u0027s very weird that you\u0027re retriving OPTS then ignoring it.\nSounds like you\u0027re not using getopt at all","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"f742e783a0a16ebf229983ddcc87d1096132b190","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d$(getopt -o hl --long help,list,exclude: -- \"$@\")"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_75885423","line":14,"in_reply_to":"ba5da102_8fdddb16","updated":"2016-10-28 05:47:27.000000000","message":"Indeed, which condition it goes highly depends on testing $1. I think this should be the way we solve the ambiguity here. \n\nSo IMO, `image_list.sh xenserver --list` should be recognized as to output xenserver image urls instead of showing drivers.\n\nI know maybe we can make the parameter interpretation more sophisticated. But we don\u0027t want to over deign this small tool, right?\n\nPlease forgive me if I didn\u0027t actually get your point. I do really appreciate your direction since you are on board for this. :-)","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"f742e783a0a16ebf229983ddcc87d1096132b190","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d$(getopt -o hl --long help,list,exclude: -- \"$@\")"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_1af747d4","line":14,"in_reply_to":"ba5da102_d7377ae1","updated":"2016-10-28 05:47:27.000000000","message":"I guess you were meaning getopts. But getopts and getopt are two different things. They are functionally equivalent except getopts only handles single-dash parameters. The reason getopt is used here is because Ian suggested it at first.","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"c07813c70d3a96387f529543b518af3ba9a7d073","unresolved":false,"context_lines":[{"line_number":11,"context_line":"HOST_IP\u003dSKIP"},{"line_number":12,"context_line":"source $TOP_DIR/functions"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"OPTS\u003d$(getopt -o hl --long help,list,exclude: -- \"$@\")"},{"line_number":15,"context_line":"DRIVERS\u003d\"$(source $TOP_DIR/stackrc \u0026\u0026 echo $DEVSTACK_SUPPORTED_VIRT_DRIVERS)\""},{"line_number":16,"context_line":"EXCLUSION\u003d\"\""},{"line_number":17,"context_line":"while true; do"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_8fdddb16","line":14,"in_reply_to":"ba5da102_d7377ae1","updated":"2016-10-28 00:57:32.000000000","message":"yes, I think you need to eval the output of \"getopt\"\n\nbut I think this also pretty much works because it\u0027s testing $1 below, which is set to the argument when you\u0027re testing it i\u0027m sure.  but would break if listing the drivers.\n\nso yeah, needs some work","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"c5739a9fba13a9c3c61d1e330dca5f7dfca79be1","unresolved":false,"context_lines":[{"line_number":18,"context_line":"    case \"$1\" in"},{"line_number":19,"context_line":"        -l | --list ) echo \"$DRIVERS\" | tr \u0027 \u0027 \u0027\\n\u0027 | sort | uniq ; exit 0 ;;"},{"line_number":20,"context_line":"        --exclude ) shift ; EXCLUSION\u003d\"$@\"; break ;;"},{"line_number":21,"context_line":"        -h | --help ) echo -e \""},{"line_number":22,"context_line":"Show pre-caching image urls"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"Usage:"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_d4093833","line":21,"updated":"2016-10-27 10:34:45.000000000","message":"This should typically be split out into a usage function","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"f742e783a0a16ebf229983ddcc87d1096132b190","unresolved":false,"context_lines":[{"line_number":18,"context_line":"    case \"$1\" in"},{"line_number":19,"context_line":"        -l | --list ) echo \"$DRIVERS\" | tr \u0027 \u0027 \u0027\\n\u0027 | sort | uniq ; exit 0 ;;"},{"line_number":20,"context_line":"        --exclude ) shift ; EXCLUSION\u003d\"$@\"; break ;;"},{"line_number":21,"context_line":"        -h | --help ) echo -e \""},{"line_number":22,"context_line":"Show pre-caching image urls"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"Usage:"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_5a01bfad","line":21,"in_reply_to":"ba5da102_d4093833","updated":"2016-10-28 05:47:27.000000000","message":"Done","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"c07813c70d3a96387f529543b518af3ba9a7d073","unresolved":false,"context_lines":[{"line_number":22,"context_line":"Show pre-caching image urls"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"Usage:"},{"line_number":25,"context_line":"./image_list.sh [options]"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"Options:"},{"line_number":28,"context_line":"-h, --help \\t A brief usage guide"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_8fb6bbda","line":25,"updated":"2016-10-28 00:57:32.000000000","message":"nit but this should be something like\n\n ./image_list [--exclude] [\u003cdriver1\u003e \u003cdriver2\u003e ...]","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":17169,"name":"John Hua","email":"ihuazhihao@gmail.com","username":"johnhua"},"change_message_id":"f742e783a0a16ebf229983ddcc87d1096132b190","unresolved":false,"context_lines":[{"line_number":22,"context_line":"Show pre-caching image urls"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"Usage:"},{"line_number":25,"context_line":"./image_list.sh [options]"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"Options:"},{"line_number":28,"context_line":"-h, --help \\t A brief usage guide"}],"source_content_type":"text/x-sh","patch_set":11,"id":"ba5da102_9a8d1734","line":25,"in_reply_to":"ba5da102_8fb6bbda","updated":"2016-10-28 05:47:27.000000000","message":"Done","commit_id":"8b75646f7860e55767307c4200b473364df862c0"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"f2a699bde2abbc43a5f481d3aa3350545a496c4b","unresolved":false,"context_lines":[{"line_number":3,"context_line":"# Keep track of the DevStack directory"},{"line_number":4,"context_line":"TOP_DIR\u003d$(cd $(dirname \"$0\")/.. \u0026\u0026 pwd)"},{"line_number":5,"context_line":""},{"line_number":6,"context_line":"usage()"},{"line_number":7,"context_line":"{"},{"line_number":8,"context_line":"cat \u003c\u003c EOF"},{"line_number":9,"context_line":"Show pre-caching image urls"}],"source_content_type":"text/x-sh","patch_set":15,"id":"ba5da102_f4c6ea47","line":6,"updated":"2016-10-31 22:59:15.000000000","message":"one nit here, our standard is to use \n\nfunction usage {\n ...\n}\n\nbashate should have caught this ... interesting","commit_id":"82afe8157340e65d559bd106ccbc00854855bb5f"}]}
