)]}'
{"install/storlets/install_storlets.sh":[{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# 3. Deployment over existing Swift cluster"},{"line_number":8,"context_line":"if [ \"$#\" -ne 1 ]; then"},{"line_number":9,"context_line":"    echo \"Usage: s2aio.sh \u003cflavour\u003e\""},{"line_number":10,"context_line":"    echo \"flavour \u003d jenkins | dev | deploy | docker\""},{"line_number":11,"context_line":"    exit 1"},{"line_number":12,"context_line":"fi"},{"line_number":13,"context_line":""}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_2ffbc248","line":10,"updated":"2016-08-17 07:06:09.000000000","message":"I see no usage of flavour here, lets just delete reference to it.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# 3. Deployment over existing Swift cluster"},{"line_number":8,"context_line":"if [ \"$#\" -ne 1 ]; then"},{"line_number":9,"context_line":"    echo \"Usage: s2aio.sh \u003cflavour\u003e\""},{"line_number":10,"context_line":"    echo \"flavour \u003d jenkins | dev | deploy | docker\""},{"line_number":11,"context_line":"    exit 1"},{"line_number":12,"context_line":"fi"},{"line_number":13,"context_line":""}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_da0bc328","line":10,"in_reply_to":"3ac371cc_2ffbc248","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":1,"context_line":"#!/bin/bash"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"set -eu"},{"line_number":4,"context_line":"# echo \"Running hosts cluster_check playbook\""},{"line_number":5,"context_line":"ansible-playbook -s -i storlets_dynamic_inventory.py cluster_check.yml"},{"line_number":6,"context_line":""}],"source_content_type":"text/x-sh","patch_set":23,"id":"1ac06dbe_324a32ad","line":3,"updated":"2016-08-30 08:41:56.000000000","message":"Its always great to see lines go away","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"}],"install/storlets/prepare_storlets_install.sh":[{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":4,"context_line":"# 1. Jenkins job installation, for running the funciotal tests."},{"line_number":5,"context_line":"# 2. Developer instalation."},{"line_number":6,"context_line":"# 3. Deployment over existing Swift cluster"},{"line_number":7,"context_line":"if [ \"$#\" -gt 2 ]; then"},{"line_number":8,"context_line":"    echo \"Usage: s2aio.sh \u003cflavor\u003e [swift_ip]\""},{"line_number":9,"context_line":"    echo \"flavor \u003d jenkins | dev | deploy | docker\""},{"line_number":10,"context_line":"    exit 1"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_ef288ae4","line":7,"updated":"2016-08-17 07:06:09.000000000","message":"need to split to \u003cflavour\u003e \u003ctarget\u003e\nand adjust the conditions accordingly.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":51,"context_line":"else"},{"line_number":52,"context_line":"    cp installation_vars.yml-sample deploy/installation_vars.yml"},{"line_number":53,"context_line":"    if [ $SWIFT_IP \u003d\u003d \u0027127.0.0.1\u0027 ]; then"},{"line_number":54,"context_line":"        sed -i \u0027s/\u003cANSIBLE_USER\u003e/\u0027$USER\u0027/g\u0027 deploy/installation_vars.yml"},{"line_number":55,"context_line":"        sed -i \u0027s/\u003cMGMT_USER\u003e/\u0027$USER\u0027/g\u0027 deploy/installation_vars.yml"},{"line_number":56,"context_line":"    else"},{"line_number":57,"context_line":"        sed -i \u0027s/\u003cANSIBLE_USER\u003e/root/g\u0027 deploy/installation_vars.yml"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_4f671e4d","line":54,"updated":"2016-08-17 07:06:09.000000000","message":"are lines 54,55 identical to 57,58 and can be taken out of the condition?","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":51,"context_line":"else"},{"line_number":52,"context_line":"    cp installation_vars.yml-sample deploy/installation_vars.yml"},{"line_number":53,"context_line":"    if [ $SWIFT_IP \u003d\u003d \u0027127.0.0.1\u0027 ]; then"},{"line_number":54,"context_line":"        sed -i \u0027s/\u003cANSIBLE_USER\u003e/\u0027$USER\u0027/g\u0027 deploy/installation_vars.yml"},{"line_number":55,"context_line":"        sed -i \u0027s/\u003cMGMT_USER\u003e/\u0027$USER\u0027/g\u0027 deploy/installation_vars.yml"},{"line_number":56,"context_line":"    else"},{"line_number":57,"context_line":"        sed -i \u0027s/\u003cANSIBLE_USER\u003e/root/g\u0027 deploy/installation_vars.yml"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_3016734c","line":54,"in_reply_to":"3ac371cc_4f671e4d","updated":"2016-08-17 15:50:03.000000000","message":"they are not identical.\nIn one, we replace with \u0027$USER\u0027.\nIn the other, we replace with \u0027root\u0027.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":60,"context_line":"    fi"},{"line_number":61,"context_line":"    sed -i \u0027s/\u003cSWIFT_RUNTIME_USER\u003e/swift/g\u0027 deploy/installation_vars.yml"},{"line_number":62,"context_line":"    sed -i \u0027s/\u003cSWIFT_RUNTIME_GROUP\u003e/swift/g\u0027 deploy/installation_vars.yml"},{"line_number":63,"context_line":"    if [ \"$FLAVOR\" \u003d\u003d \"jenkins\" ]; then"},{"line_number":64,"context_line":"        sed -i \u0027s/\u003cSTORLETS_REPO_ROOT\u003e/\\/home\\/\u0027$USER\u0027\\/workspace\\/gate-storlets-functional\\//g\u0027 deploy/installation_vars.yml"},{"line_number":65,"context_line":"    else"},{"line_number":66,"context_line":"        sed -i \u0027s/\u003cSTORLETS_REPO_ROOT\u003e/~\\/storlets\\//g\u0027 deploy/installation_vars.yml"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_6fc93a26","line":63,"updated":"2016-08-17 07:06:09.000000000","message":"Looks reasonable no need to change here.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"f59ac5e4eeae4fc6593461ab897507e220093f07","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# There are two possible targets:"},{"line_number":8,"context_line":"# 1. host (localhost)"},{"line_number":9,"context_line":"# 2. docker"},{"line_number":10,"context_line":"if [ \"$#\" -gt 2 ]; then"},{"line_number":11,"context_line":"    echo \"Usage: s2aio.sh \u003cflavor\u003e [target]\""},{"line_number":12,"context_line":"    echo \"flavor \u003d jenkins | dev | deploy\""},{"line_number":13,"context_line":"    echo \"target \u003d host | docker\""}],"source_content_type":"text/x-sh","patch_set":22,"id":"1ac06dbe_651d2f73","line":10,"range":{"start_line":10,"start_character":5,"end_line":10,"end_character":15},"updated":"2016-08-20 13:57:48.000000000","message":"We should abort with the usage also if $# \u003d\u003d 1","commit_id":"9cc9a55391e91519a396957fcb452194805a716a"},{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"c5b34fe1555539f5178d91a0ba60997a92618bd0","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# There are two possible targets:"},{"line_number":8,"context_line":"# 1. host (localhost)"},{"line_number":9,"context_line":"# 2. docker"},{"line_number":10,"context_line":"if [ \"$#\" -gt 2 ]; then"},{"line_number":11,"context_line":"    echo \"Usage: s2aio.sh \u003cflavor\u003e [target]\""},{"line_number":12,"context_line":"    echo \"flavor \u003d jenkins | dev | deploy\""},{"line_number":13,"context_line":"    echo \"target \u003d host | docker\""}],"source_content_type":"text/x-sh","patch_set":22,"id":"1ac06dbe_549ffa4f","line":10,"range":{"start_line":10,"start_character":5,"end_line":10,"end_character":15},"in_reply_to":"1ac06dbe_0c7580f8","updated":"2016-08-21 04:18:29.000000000","message":"I noticed I should say $# \u003d\u003d 0, and thank you for updating.","commit_id":"9cc9a55391e91519a396957fcb452194805a716a"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"8a3c0fc940cf08fc209e17d4d36e41eaf31017a8","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# There are two possible targets:"},{"line_number":8,"context_line":"# 1. host (localhost)"},{"line_number":9,"context_line":"# 2. docker"},{"line_number":10,"context_line":"if [ \"$#\" -gt 2 ]; then"},{"line_number":11,"context_line":"    echo \"Usage: s2aio.sh \u003cflavor\u003e [target]\""},{"line_number":12,"context_line":"    echo \"flavor \u003d jenkins | dev | deploy\""},{"line_number":13,"context_line":"    echo \"target \u003d host | docker\""}],"source_content_type":"text/x-sh","patch_set":22,"id":"1ac06dbe_0c7580f8","line":10,"range":{"start_line":10,"start_character":5,"end_line":10,"end_character":15},"in_reply_to":"1ac06dbe_651d2f73","updated":"2016-08-20 18:53:05.000000000","message":"actually, the second parameter is optional (it is \u0027host\u0027 by default). But I now abort when there are no parameters at all.","commit_id":"9cc9a55391e91519a396957fcb452194805a716a"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# There are two possible targets:"},{"line_number":8,"context_line":"# 1. host (localhost)"},{"line_number":9,"context_line":"# 2. docker"},{"line_number":10,"context_line":"if [ \"$#\" -eq 0 ] || [ \"$#\" -gt 2 ]; then"},{"line_number":11,"context_line":"    echo \"Usage: s2aio.sh \u003cflavor\u003e [target]\""},{"line_number":12,"context_line":"    echo \"flavor \u003d jenkins | dev | deploy\""},{"line_number":13,"context_line":"    echo \"target \u003d host | docker\""}],"source_content_type":"text/x-sh","patch_set":23,"id":"1ac06dbe_b5856c08","line":10,"updated":"2016-08-30 08:41:56.000000000","message":"Any reason not to assume we always get two parameters here, and simplify the code?","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# There are two possible targets:"},{"line_number":8,"context_line":"# 1. host (localhost)"},{"line_number":9,"context_line":"# 2. docker"},{"line_number":10,"context_line":"if [ \"$#\" -eq 0 ] || [ \"$#\" -gt 2 ]; then"},{"line_number":11,"context_line":"    echo \"Usage: s2aio.sh \u003cflavor\u003e [target]\""},{"line_number":12,"context_line":"    echo \"flavor \u003d jenkins | dev | deploy\""},{"line_number":13,"context_line":"    echo \"target \u003d host | docker\""}],"source_content_type":"text/x-sh","patch_set":23,"id":"9a89bdaa_322531ab","line":10,"in_reply_to":"1ac06dbe_b5856c08","updated":"2016-09-03 14:03:55.000000000","message":"Done","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"}],"install/storlets/roles/docker_base_jre_image/templates/ubuntu_14.04_jre8_Dockerfile":[{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"f59ac5e4eeae4fc6593461ab897507e220093f07","unresolved":false,"context_lines":[{"line_number":28,"context_line":"    apt-get install oracle-java8-installer -y --force-yes \u0026\u0026 \\"},{"line_number":29,"context_line":"    apt-get clean"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"COPY [\"logback-classic-1.1.2.jar\", \"logback-core-1.1.2.jar\", \"slf4j-api-1.7.7.jar\", \"json_simple-1.1.jar\", \"/opt/storlets/\"]"},{"line_number":32,"context_line":"RUN [\"chmod\", \"0744\", \"/opt/storlets/logback-classic-1.1.2.jar\", \"/opt/storlets/logback-core-1.1.2.jar\", \"/opt/storlets/slf4j-api-1.7.7.jar\", \"/opt/storlets/json_simple-1.1.jar\"]"}],"source_content_type":"application/octet-stream","patch_set":22,"id":"1ac06dbe_582bb682","line":32,"range":{"start_line":31,"start_character":0,"end_line":32,"end_character":178},"updated":"2016-08-20 13:57:48.000000000","message":"Good improvement to remove unnecessary image layers.","commit_id":"9cc9a55391e91519a396957fcb452194805a716a"}],"install/storlets/roles/docker_client/tasks/main.yml":[{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    insertafter: \"^DOCKER_OPTS\u003d\""},{"line_number":100,"context_line":"  when: \"\u00272\u0027 in opt_lines_count.stdout\""},{"line_number":101,"context_line":""},{"line_number":102,"context_line":"- name: Stop Docker Daemon"},{"line_number":103,"context_line":"  shell: bash -c \"/usr/sbin/service docker stop\""},{"line_number":104,"context_line":"  ignore_errors: yes"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-yaml","patch_set":23,"id":"1ac06dbe_352b3c96","line":102,"updated":"2016-08-30 08:41:56.000000000","message":"If we can do stop and then start it would be better. Easier to upgrade to 15.04 and 16.04 where there is no \"service\" subsystem.\n\nDid you try:\n- name: Stop Docker Daemon\n  service:\n    name: docker\n    state: stopped\n    ignore_errors: yes\n\n- name: Allow daemon to stop.\n  pause: seconds\u003d1\n\n- name: Start Docker Daemon\n  service:\n    name: docker\n    state: started","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":99,"context_line":"    insertafter: \"^DOCKER_OPTS\u003d\""},{"line_number":100,"context_line":"  when: \"\u00272\u0027 in opt_lines_count.stdout\""},{"line_number":101,"context_line":""},{"line_number":102,"context_line":"- name: Stop Docker Daemon"},{"line_number":103,"context_line":"  shell: bash -c \"/usr/sbin/service docker stop\""},{"line_number":104,"context_line":"  ignore_errors: yes"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-yaml","patch_set":23,"id":"9a89bdaa_72ac19ee","line":102,"in_reply_to":"1ac06dbe_352b3c96","updated":"2016-09-03 14:03:55.000000000","message":"\"upgrade to 15.04\" -- I assume you mean the ubuntu docker image? Neither 15.04 nor 16.04 work as is. Changing to a different Ubuntu image would cause the \"docker\" and \"host\" installations to diverge further.\nI don\u0027t know why the \"service\" ansible module does not work for me within the docker container. This is the only way around it that I could find (the only way which both works and passes the pep8 test).","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":106,"context_line":"- name: Restart Docker Daemon"},{"line_number":107,"context_line":"  shell: bash -c \"/usr/sbin/service docker start\""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"- name: wait a sec"},{"line_number":110,"context_line":"  shell: sleep 1"}],"source_content_type":"text/x-yaml","patch_set":23,"id":"1ac06dbe_18147542","line":109,"updated":"2016-08-30 08:41:56.000000000","message":"I assume the wait should be between the start and stop..","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":106,"context_line":"- name: Restart Docker Daemon"},{"line_number":107,"context_line":"  shell: bash -c \"/usr/sbin/service docker start\""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"- name: wait a sec"},{"line_number":110,"context_line":"  shell: sleep 1"}],"source_content_type":"text/x-yaml","patch_set":23,"id":"9a89bdaa_5268f5ba","line":109,"in_reply_to":"1ac06dbe_18147542","updated":"2016-09-03 14:03:55.000000000","message":"Not needed. Removing","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"}],"install/swift/install_swift.sh":[{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":17,"context_line":"SWIFT_IP\u003d\u0027127.0.0.1\u0027"},{"line_number":18,"context_line":"DEVICE\u003d\u0027loop0\u0027"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"if [ \"$#\" -gt 2 ]; then"},{"line_number":21,"context_line":"    echo \"Usage: $0 [ip_of_machine] [device-name]\";"},{"line_number":22,"context_line":"    exit"},{"line_number":23,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_ea151840","line":20,"updated":"2016-08-17 07:06:09.000000000","message":"I think that this script really need to get the target, and IP (you can pass 127.0.0.1 if the target is host to ease on the input verification)\n\nUsage: $0 [target] [ip] [device name]\ntarget \u003d host | docker\netc.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":17,"context_line":"SWIFT_IP\u003d\u0027127.0.0.1\u0027"},{"line_number":18,"context_line":"DEVICE\u003d\u0027loop0\u0027"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"if [ \"$#\" -gt 2 ]; then"},{"line_number":21,"context_line":"    echo \"Usage: $0 [ip_of_machine] [device-name]\";"},{"line_number":22,"context_line":"    exit"},{"line_number":23,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_f0e69bae","line":20,"in_reply_to":"3ac371cc_ea151840","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":44,"context_line":"    sudo sed -i \u0027s/\u003cset dir!\u003e/\u0027$REPODIR_REPLACE\u0027/g\u0027 vars.yml"},{"line_number":45,"context_line":"fi"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"if [ $SWIFT_IP !\u003d \u0027127.0.0.1\u0027 ]; then"},{"line_number":48,"context_line":"    sed -i \u0027s/127.0.0.1/\u0027$SWIFT_IP\u0027/g\u0027 hosts"},{"line_number":49,"context_line":"    sed -i \u0027s/127.0.0.1/\u0027$SWIFT_IP\u0027/g\u0027 templates/cluster_config"},{"line_number":50,"context_line":"    cat \u003e\u003e hosts \u003c\u003cEOF"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_4a7b8c8c","line":47,"updated":"2016-08-17 07:06:09.000000000","message":"here you can unconditionally do the replacement. worse case you replace 127.0.0.1 with 127.0.0.1","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":44,"context_line":"    sudo sed -i \u0027s/\u003cset dir!\u003e/\u0027$REPODIR_REPLACE\u0027/g\u0027 vars.yml"},{"line_number":45,"context_line":"fi"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"if [ $SWIFT_IP !\u003d \u0027127.0.0.1\u0027 ]; then"},{"line_number":48,"context_line":"    sed -i \u0027s/127.0.0.1/\u0027$SWIFT_IP\u0027/g\u0027 hosts"},{"line_number":49,"context_line":"    sed -i \u0027s/127.0.0.1/\u0027$SWIFT_IP\u0027/g\u0027 templates/cluster_config"},{"line_number":50,"context_line":"    cat \u003e\u003e hosts \u003c\u003cEOF"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_70fbcb47","line":47,"in_reply_to":"3ac371cc_4a7b8c8c","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":61,"context_line":"# running processes (e.g. swift-init proxy stop for clean environment) and"},{"line_number":62,"context_line":"# it will make a non zero exit code causes gate failure so remove set -eu"},{"line_number":63,"context_line":"# trusting those script. (Hopefully, it could be solved in the script)"},{"line_number":64,"context_line":"if [ $SWIFT_IP \u003d\u003d \u0027127.0.0.1\u0027 ]; then"},{"line_number":65,"context_line":"    cd $REPODIR/swift-install/provisioning"},{"line_number":66,"context_line":"    ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml"},{"line_number":67,"context_line":"else"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_0a5eb411","line":64,"updated":"2016-08-17 07:06:09.000000000","message":"if target \u003d\u003d host","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    cd $REPODIR/swift-install/provisioning"},{"line_number":66,"context_line":"    ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml"},{"line_number":67,"context_line":"else"},{"line_number":68,"context_line":"    ssh root@$SWIFT_IP \u0027ssh-keygen -q -t rsa -f ~/.ssh/id_rsa -N \"\"\u0027"},{"line_number":69,"context_line":"    ssh root@$SWIFT_IP \u0027cat ~/.ssh/id_rsa.pub \u003e\u003e ~/.ssh/authorized_keys\u0027"},{"line_number":70,"context_line":"    ssh root@$SWIFT_IP \"bash -c \u0027cd /tmp/swift-install/provisioning ; ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml\u0027\""},{"line_number":71,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_0ab51430","line":68,"updated":"2016-08-17 07:06:09.000000000","message":"I think that the first two lines belong to s2aio.sh - Am I missing something?","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    cd $REPODIR/swift-install/provisioning"},{"line_number":66,"context_line":"    ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml"},{"line_number":67,"context_line":"else"},{"line_number":68,"context_line":"    ssh root@$SWIFT_IP \u0027ssh-keygen -q -t rsa -f ~/.ssh/id_rsa -N \"\"\u0027"},{"line_number":69,"context_line":"    ssh root@$SWIFT_IP \u0027cat ~/.ssh/id_rsa.pub \u003e\u003e ~/.ssh/authorized_keys\u0027"},{"line_number":70,"context_line":"    ssh root@$SWIFT_IP \"bash -c \u0027cd /tmp/swift-install/provisioning ; ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml\u0027\""},{"line_number":71,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_10ced781","line":68,"in_reply_to":"3ac371cc_0ab51430","updated":"2016-08-17 15:50:03.000000000","message":"These lines are performed remotely within the docker container. We want to allow the ansible running on the docker container, to be able to ssh to the docker container.\nIn s2aio we dealt with allowing the user on the host to login to other machines.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# This is a dev oriented Swift installation that"},{"line_number":8,"context_line":"# uses Keystone and a single device for all rings."},{"line_number":9,"context_line":"# TODO: Move swift ansible scripts pull from here"},{"line_number":10,"context_line":"# to the swift-install module "},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"# The script takes a block device name as an optional parameter"},{"line_number":13,"context_line":"# The device name can be either \u0027loop0\u0027 or any block device under /dev"}],"source_content_type":"text/x-sh","patch_set":23,"id":"1ac06dbe_afa23d49","line":10,"updated":"2016-08-30 08:41:56.000000000","message":"pls delete space at the end of the line","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":7,"context_line":"# This is a dev oriented Swift installation that"},{"line_number":8,"context_line":"# uses Keystone and a single device for all rings."},{"line_number":9,"context_line":"# TODO: Move swift ansible scripts pull from here"},{"line_number":10,"context_line":"# to the swift-install module "},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"# The script takes a block device name as an optional parameter"},{"line_number":13,"context_line":"# The device name can be either \u0027loop0\u0027 or any block device under /dev"}],"source_content_type":"text/x-sh","patch_set":23,"id":"9a89bdaa_92b99d31","line":10,"in_reply_to":"1ac06dbe_afa23d49","updated":"2016-09-03 14:03:55.000000000","message":"Done","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    cd $REPODIR/swift-install/provisioning"},{"line_number":66,"context_line":"    ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml"},{"line_number":67,"context_line":"else"},{"line_number":68,"context_line":"    ssh root@$SWIFT_IP \u0027ssh-keygen -q -t rsa -f ~/.ssh/id_rsa -N \"\"\u0027"},{"line_number":69,"context_line":"    ssh root@$SWIFT_IP \u0027cat ~/.ssh/id_rsa.pub \u003e\u003e ~/.ssh/authorized_keys\u0027"},{"line_number":70,"context_line":"    ssh root@$SWIFT_IP \"bash -c \u0027cd /tmp/swift-install/provisioning ; ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml\u0027\""},{"line_number":71,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":23,"id":"1ac06dbe_5277ee39","line":68,"updated":"2016-08-30 08:41:56.000000000","message":"Seems like lines 68,69 belong to s2aio.sh near what\u0027s done there in lines 58-60. Does it make sense to move it there?\nAlso, for the sake of re-enterency it seems best to do the keygen only if the key does not exists, e.g.\nssh root@$SWIFT_IP \u0027if [! -f ~/.ssh/id_rsa ]; then ssh-keygen -q -t rsa -f ~/.ssh/id_rsa -N \"\"; fi`","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    cd $REPODIR/swift-install/provisioning"},{"line_number":66,"context_line":"    ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml"},{"line_number":67,"context_line":"else"},{"line_number":68,"context_line":"    ssh root@$SWIFT_IP \u0027ssh-keygen -q -t rsa -f ~/.ssh/id_rsa -N \"\"\u0027"},{"line_number":69,"context_line":"    ssh root@$SWIFT_IP \u0027cat ~/.ssh/id_rsa.pub \u003e\u003e ~/.ssh/authorized_keys\u0027"},{"line_number":70,"context_line":"    ssh root@$SWIFT_IP \"bash -c \u0027cd /tmp/swift-install/provisioning ; ansible-playbook -s -i swift_dynamic_inventory.py main-install.yml\u0027\""},{"line_number":71,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":23,"id":"9a89bdaa_d2e88519","line":68,"in_reply_to":"1ac06dbe_5277ee39","updated":"2016-09-03 14:03:55.000000000","message":"Done","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"}],"install/swift/roles/pull_swift_ansible/tasks/main.yml":[{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":33,"context_line":"       version\u003d\"HEAD\""},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"- name: Copy cluster_config.json to the swift install location"},{"line_number":36,"context_line":"  shell: cp /tmp/cluster_config.json \"{{ swift_install_reop_dir }}/{{ swift_install_repo_name }}/provisioning/cluster_config.json\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"- file: mode\u003d1777 path\u003d\"{{ swift_install_reop_dir }}/{{swift_install_repo_name}}\""}],"source_content_type":"text/x-yaml","patch_set":23,"id":"1ac06dbe_782e49fb","line":36,"updated":"2016-08-30 08:41:56.000000000","message":"I am not sure why this change is required. That is both here and in the prepare_swift_install.yml where we create the files from templates into /tmp\n\nIMHO, the best way is just to migrate the below from prepare_swift_install.yml to here and save the copy altogether (be it a shell copy or Ansible copy).\n\n- name: cluster_config.json from template\n  hosts: s2aio\n  vars_files:\n  - [vars.yml]\n  tasks:\n  - stat: path\u003d\"{{playbook_dir}}/cluster_config.json\"\n    register: st0\n\n  - template:\n      src: templates/cluster_config\n      dest: \"{{ playbook_dir }}/cluster_config.json\"\n    when: not st0.stat.exists","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":33,"context_line":"       version\u003d\"HEAD\""},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"- name: Copy cluster_config.json to the swift install location"},{"line_number":36,"context_line":"  shell: cp /tmp/cluster_config.json \"{{ swift_install_reop_dir }}/{{ swift_install_repo_name }}/provisioning/cluster_config.json\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"- file: mode\u003d1777 path\u003d\"{{ swift_install_reop_dir }}/{{swift_install_repo_name}}\""}],"source_content_type":"text/x-yaml","patch_set":23,"id":"9a89bdaa_b203010f","line":36,"in_reply_to":"1ac06dbe_782e49fb","updated":"2016-09-03 14:03:55.000000000","message":"In prepare_swift_install.yml we have the following lines:\n\n- template:\n      src: templates/cluster_config\n      dest: \"{{ playbook_dir }}/cluster_config.json\"\n\nThis is an error, as it assumes that directory \"{{ playbook_dir }}\" exists on the remote host. That is why I moved it to /tmp. This is the least intrusive change I could make.","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"bfc8ca2fcadb76db444cef0d89c6d92a18d8cee2","unresolved":false,"context_lines":[{"line_number":33,"context_line":"       version\u003d\"HEAD\""},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"- name: Copy cluster_config.json to the swift install location"},{"line_number":36,"context_line":"  shell: cp /tmp/cluster_config.json \"{{ swift_install_reop_dir }}/{{ swift_install_repo_name }}/provisioning/cluster_config.json\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"- file: mode\u003d1777 path\u003d\"{{ swift_install_reop_dir }}/{{swift_install_repo_name}}\""}],"source_content_type":"text/x-yaml","patch_set":29,"id":"9a89bdaa_2be8577c","line":36,"range":{"start_line":36,"start_character":0,"end_line":36,"end_character":130},"updated":"2016-09-04 10:12:05.000000000","message":"Is there any reason why we need to execute cp via shell instead of using  \u0027copy\u0027 in ansibile?","commit_id":"daeee5e20b924830f7e419d2174bec4c667204fb"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"86d93c93933f60b14097c689b9eee16b26ff5880","unresolved":false,"context_lines":[{"line_number":33,"context_line":"       version\u003d\"HEAD\""},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"- name: Copy cluster_config.json to the swift install location"},{"line_number":36,"context_line":"  shell: cp /tmp/cluster_config.json \"{{ swift_install_reop_dir }}/{{ swift_install_repo_name }}/provisioning/cluster_config.json\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"- file: mode\u003d1777 path\u003d\"{{ swift_install_reop_dir }}/{{swift_install_repo_name}}\""}],"source_content_type":"text/x-yaml","patch_set":29,"id":"9a89bdaa_a6ad7e8a","line":36,"range":{"start_line":36,"start_character":0,"end_line":36,"end_character":130},"in_reply_to":"9a89bdaa_2be8577c","updated":"2016-09-04 11:47:37.000000000","message":"I changed it back to using the ansible \u0027copy\u0027 module. I added the remote_src\u003dyes parameter, since the cluster_config.json file resides in the remote host.","commit_id":"daeee5e20b924830f7e419d2174bec4c667204fb"}],"s2aio.sh":[{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":6,"context_line":"# 2. Developer instalation."},{"line_number":7,"context_line":""},{"line_number":8,"context_line":"if [ \"$#\" -ne 1 ]; then"},{"line_number":9,"context_line":"    echo \"Usage: s2aio.sh \u003cflavour\u003e\""},{"line_number":10,"context_line":"    echo \"flavour \u003d jenkins | dev\""},{"line_number":11,"context_line":"    exit 1"},{"line_number":12,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_6f149a9f","line":9,"updated":"2016-08-17 07:06:09.000000000","message":"I actually think that we need a somewhat different CLI:\nSomething like s2aio.sh \u003cflavour\u003e \u003ctarget\u003e with\nflavour \u003d jenkins | dev\ntarget \u003d docker | host\n\nIn the follow-on comments I am mapping the implications\nI do apologize for the obviousness of the comments.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":6,"context_line":"# 2. Developer instalation."},{"line_number":7,"context_line":""},{"line_number":8,"context_line":"if [ \"$#\" -ne 1 ]; then"},{"line_number":9,"context_line":"    echo \"Usage: s2aio.sh \u003cflavour\u003e\""},{"line_number":10,"context_line":"    echo \"flavour \u003d jenkins | dev\""},{"line_number":11,"context_line":"    exit 1"},{"line_number":12,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_23d46fea","line":9,"in_reply_to":"3ac371cc_6f149a9f","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":12,"context_line":"fi"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"FLAVOR\u003d\"$1\""},{"line_number":15,"context_line":"if [ \"$FLAVOR\" !\u003d \"jenkins\" ] \u0026\u0026 [ \"$FLAVOR\" !\u003d \"dev\" ] \u0026\u0026 [ \"$FLAVOR\" !\u003d \"docker\" ]; then"},{"line_number":16,"context_line":"    echo \"flavour must be either \\\"jenkins\\\" or \\\"dev\\\" or \\\"docker\\\"\""},{"line_number":17,"context_line":"    exit 1"},{"line_number":18,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_6f393aa4","line":15,"updated":"2016-08-17 07:06:09.000000000","message":"remove docker from this condition and add a similar condition for $TARGET","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":12,"context_line":"fi"},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"FLAVOR\u003d\"$1\""},{"line_number":15,"context_line":"if [ \"$FLAVOR\" !\u003d \"jenkins\" ] \u0026\u0026 [ \"$FLAVOR\" !\u003d \"dev\" ] \u0026\u0026 [ \"$FLAVOR\" !\u003d \"docker\" ]; then"},{"line_number":16,"context_line":"    echo \"flavour must be either \\\"jenkins\\\" or \\\"dev\\\" or \\\"docker\\\"\""},{"line_number":17,"context_line":"    exit 1"},{"line_number":18,"context_line":"fi"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_63dae718","line":15,"in_reply_to":"3ac371cc_6f393aa4","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"install/install_ansible.sh"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"export SWIFT_IP\u003d\u0027127.0.0.1\u0027"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":28,"context_line":"    # install docker"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_4f327e60","line":25,"updated":"2016-08-17 07:06:09.000000000","message":"move after the docker installation block and change to:\nif $TARGET \u003d\u003d host\n   SWIFT_IP\u003d\u0027127.0.0.1\u0027\nelse\n   export SWIFT_IP\u003d\u0027sudo docker exec....\u0027","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":24,"context_line":""},{"line_number":25,"context_line":"export SWIFT_IP\u003d\u0027127.0.0.1\u0027"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":28,"context_line":"    # install docker"},{"line_number":29,"context_line":"    sudo apt-get install apt-transport-https aufs-tools\u003d1:3.2+20130722-1.1 linux-image-extra-`uname -r` -y --force-yes"},{"line_number":30,"context_line":"    sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_af5692cb","line":27,"updated":"2016-08-17 07:06:09.000000000","message":"if $TARGET \u003d\u003d docker","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":24,"context_line":""},{"line_number":25,"context_line":"export SWIFT_IP\u003d\u0027127.0.0.1\u0027"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":28,"context_line":"    # install docker"},{"line_number":29,"context_line":"    sudo apt-get install apt-transport-https aufs-tools\u003d1:3.2+20130722-1.1 linux-image-extra-`uname -r` -y --force-yes"},{"line_number":30,"context_line":"    sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_033fb324","line":27,"in_reply_to":"3ac371cc_af5692cb","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":53,"context_line":"fi"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"# 2. Add the key to the user\u0027s authorized keys"},{"line_number":56,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":57,"context_line":"    sudo docker exec swift mkdir /root/.ssh"},{"line_number":58,"context_line":"    sudo docker exec swift bash -c \"echo `cat ~/.ssh/id_rsa.pub` \u003e /root/.ssh/authorized_keys\""},{"line_number":59,"context_line":"else"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_af24d25f","line":56,"updated":"2016-08-17 07:06:09.000000000","message":"if $TARGET \u003d\u003d docker","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":53,"context_line":"fi"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"# 2. Add the key to the user\u0027s authorized keys"},{"line_number":56,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":57,"context_line":"    sudo docker exec swift mkdir /root/.ssh"},{"line_number":58,"context_line":"    sudo docker exec swift bash -c \"echo `cat ~/.ssh/id_rsa.pub` \u003e /root/.ssh/authorized_keys\""},{"line_number":59,"context_line":"else"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_634827cd","line":56,"in_reply_to":"3ac371cc_af24d25f","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":61,"context_line":"fi"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"# 3. Take care of host key verification for the current user"},{"line_number":64,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":65,"context_line":"    touch ~/.ssh/known_hosts"},{"line_number":66,"context_line":"    ssh-keygen -R $SWIFT_IP -f ~/.ssh/known_hosts"},{"line_number":67,"context_line":"    ssh-keyscan  -H $SWIFT_IP \u003e\u003e ~/.ssh/known_hosts"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_4fbd5eb6","line":64,"updated":"2016-08-17 07:06:09.000000000","message":"if $TARGET \u003d\u003d \"docker\"","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":61,"context_line":"fi"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"# 3. Take care of host key verification for the current user"},{"line_number":64,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":65,"context_line":"    touch ~/.ssh/known_hosts"},{"line_number":66,"context_line":"    ssh-keygen -R $SWIFT_IP -f ~/.ssh/known_hosts"},{"line_number":67,"context_line":"    ssh-keyscan  -H $SWIFT_IP \u003e\u003e ~/.ssh/known_hosts"}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_43452bb1","line":64,"in_reply_to":"3ac371cc_4fbd5eb6","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":86,"context_line":"# TODO: move gcc to swift-installation"},{"line_number":87,"context_line":"sudo apt-get install -y gcc --force-yes"},{"line_number":88,"context_line":"cd install/swift"},{"line_number":89,"context_line":"./install_swift.sh $SWIFT_IP"},{"line_number":90,"context_line":"cd -"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"install/storlets/prepare_storlets_install.sh \"$FLAVOR\" \"$SWIFT_IP\""}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_4ad70c4b","line":89,"updated":"2016-08-17 07:06:09.000000000","message":"./install_swift.sh $TARGET $SWIFT_IP\nsee more comments in swift_install.sh","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":86,"context_line":"# TODO: move gcc to swift-installation"},{"line_number":87,"context_line":"sudo apt-get install -y gcc --force-yes"},{"line_number":88,"context_line":"cd install/swift"},{"line_number":89,"context_line":"./install_swift.sh $SWIFT_IP"},{"line_number":90,"context_line":"cd -"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"install/storlets/prepare_storlets_install.sh \"$FLAVOR\" \"$SWIFT_IP\""}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_e30a5778","line":89,"in_reply_to":"3ac371cc_4ad70c4b","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":93,"context_line":""},{"line_number":94,"context_line":"# Install Storlets"},{"line_number":95,"context_line":"cd install/storlets"},{"line_number":96,"context_line":"./install_storlets.sh \"$FLAVOR\""},{"line_number":97,"context_line":"cd -"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"# TODO: this is for tests. Deal accordingly."}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_4f9c3e0f","line":96,"updated":"2016-08-17 07:06:09.000000000","message":"I think that install_storlets does not use $FLAVOR if this is the case, lets get rid of it.","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":93,"context_line":""},{"line_number":94,"context_line":"# Install Storlets"},{"line_number":95,"context_line":"cd install/storlets"},{"line_number":96,"context_line":"./install_storlets.sh \"$FLAVOR\""},{"line_number":97,"context_line":"cd -"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"# TODO: this is for tests. Deal accordingly."}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_e381b7c4","line":96,"in_reply_to":"3ac371cc_4f9c3e0f","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"4c410eb337c9f11a01087dba3f1fdece77a7995e","unresolved":false,"context_lines":[{"line_number":100,"context_line":"cp install/storlets/deploy/cluster_config.json ."},{"line_number":101,"context_line":"sudo chown $USER:$USER cluster_config.json"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":104,"context_line":"    sudo docker exec swift service rsyslog restart"},{"line_number":105,"context_line":"fi"},{"line_number":106,"context_line":""}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_2f48e2cb","line":103,"updated":"2016-08-17 07:06:09.000000000","message":"Can this be done right after the docker run command in the above block?","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"9962f586f133cdae1d564ab3c0b9f5811ad7ec38","unresolved":false,"context_lines":[{"line_number":100,"context_line":"cp install/storlets/deploy/cluster_config.json ."},{"line_number":101,"context_line":"sudo chown $USER:$USER cluster_config.json"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"if [ \"$FLAVOR\" \u003d\u003d \"docker\" ]; then"},{"line_number":104,"context_line":"    sudo docker exec swift service rsyslog restart"},{"line_number":105,"context_line":"fi"},{"line_number":106,"context_line":""}],"source_content_type":"text/x-sh","patch_set":21,"id":"3ac371cc_c3863bda","line":103,"in_reply_to":"3ac371cc_2f48e2cb","updated":"2016-08-17 15:50:03.000000000","message":"Done","commit_id":"1eae5245697fa8fe8a57a4423370867890bbfa89"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":29,"context_line":""},{"line_number":30,"context_line":"install/install_ansible.sh"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"if [ \"$TARGET\" \u003d\u003d \"docker\" ]; then"},{"line_number":33,"context_line":"    # install docker"},{"line_number":34,"context_line":"    sudo apt-get install apt-transport-https aufs-tools\u003d1:3.2+20130722-1.1 linux-image-extra-`uname -r` -y --force-yes"},{"line_number":35,"context_line":"    sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D"}],"source_content_type":"text/x-sh","patch_set":23,"id":"1ac06dbe_1fe744e5","line":32,"updated":"2016-08-30 08:41:56.000000000","message":"Lines 32 - 101 include 3X if [ \"$TARGET \u003d\u003d \"docker\" ] where the ONLY mutual code is in lines 54-60, 94,95 and 102.\n\nI suggest to do 54-60, and 94 before the first condition.\nMerge the 3 into one condition, duplicating 95. 102 in both blocks.","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":29,"context_line":""},{"line_number":30,"context_line":"install/install_ansible.sh"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"if [ \"$TARGET\" \u003d\u003d \"docker\" ]; then"},{"line_number":33,"context_line":"    # install docker"},{"line_number":34,"context_line":"    sudo apt-get install apt-transport-https aufs-tools\u003d1:3.2+20130722-1.1 linux-image-extra-`uname -r` -y --force-yes"},{"line_number":35,"context_line":"    sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D"}],"source_content_type":"text/x-sh","patch_set":23,"id":"9a89bdaa_6d935ca4","line":32,"in_reply_to":"1ac06dbe_1fe744e5","updated":"2016-09-03 14:03:55.000000000","message":"Done","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":38,"context_line":"    sudo apt-get install docker-engine -y --force-yes"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    # run the swift docker container"},{"line_number":41,"context_line":"    sudo docker run -i -d --privileged\u003dtrue --name swift -t ubuntu:14.04"},{"line_number":42,"context_line":"    export SWIFT_IP\u003d`sudo docker exec swift ifconfig | grep \"inet addr\" | head -1 | awk \u0027{print $2}\u0027 | awk -F\":\" \u0027{print $2}\u0027`"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    sudo docker exec swift apt-get update"}],"source_content_type":"text/x-sh","patch_set":23,"id":"1ac06dbe_1c99126f","line":41,"updated":"2016-08-30 08:41:56.000000000","message":"This will fail if a swift docker container is already created (running or not). Happened to me.\nHow about the following, which allows re-running script upon failures :\nSWIFT_RUNNING\u003d`sudo docker ps | grep swift | wc -l`\nSWIFT_EXISTS\u003d`sudo docker ps -a | grep swift | wc -l`\nif [ \"$SWIFT_RUNNING\" \u003d\u003d \"0\"]; then\n    if [\"$SWIFT_EXISTS\" \u003d\u003d \"1\"]; then\n        sudo docker rm swift\n    fi\n    sudo docker run -i -d....\nfi","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":38,"context_line":"    sudo apt-get install docker-engine -y --force-yes"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    # run the swift docker container"},{"line_number":41,"context_line":"    sudo docker run -i -d --privileged\u003dtrue --name swift -t ubuntu:14.04"},{"line_number":42,"context_line":"    export SWIFT_IP\u003d`sudo docker exec swift ifconfig | grep \"inet addr\" | head -1 | awk \u0027{print $2}\u0027 | awk -F\":\" \u0027{print $2}\u0027`"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    sudo docker exec swift apt-get update"}],"source_content_type":"text/x-sh","patch_set":23,"id":"9a89bdaa_72c17980","line":41,"in_reply_to":"1ac06dbe_1c99126f","updated":"2016-09-03 14:03:55.000000000","message":"Done","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":61,"context_line":""},{"line_number":62,"context_line":"# 2. Add the key to the user\u0027s authorized keys"},{"line_number":63,"context_line":"if [ \"$TARGET\" \u003d\u003d \"docker\" ]; then"},{"line_number":64,"context_line":"    sudo docker exec swift mkdir /root/.ssh"},{"line_number":65,"context_line":"    sudo docker exec swift bash -c \"echo `cat ~/.ssh/id_rsa.pub` \u003e /root/.ssh/authorized_keys\""},{"line_number":66,"context_line":"else"},{"line_number":67,"context_line":"    grep -s -F ${USER} ~/.ssh/authorized_keys || cat ~/.ssh/id_rsa.pub \u003e\u003e ~/.ssh/authorized_keys"}],"source_content_type":"text/x-sh","patch_set":23,"id":"fa7ab95a_654b805a","line":64,"updated":"2016-08-30 08:41:56.000000000","message":"Please change to mkdir -p\nto allow this to be re-enterent","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"},{"author":{"_account_id":8330,"name":"Doron Chen","email":"cdoron@il.ibm.com","username":"cdoron"},"change_message_id":"dcd3dccef1d0093834b0ada2135a7d785e6f3bd3","unresolved":false,"context_lines":[{"line_number":61,"context_line":""},{"line_number":62,"context_line":"# 2. Add the key to the user\u0027s authorized keys"},{"line_number":63,"context_line":"if [ \"$TARGET\" \u003d\u003d \"docker\" ]; then"},{"line_number":64,"context_line":"    sudo docker exec swift mkdir /root/.ssh"},{"line_number":65,"context_line":"    sudo docker exec swift bash -c \"echo `cat ~/.ssh/id_rsa.pub` \u003e /root/.ssh/authorized_keys\""},{"line_number":66,"context_line":"else"},{"line_number":67,"context_line":"    grep -s -F ${USER} ~/.ssh/authorized_keys || cat ~/.ssh/id_rsa.pub \u003e\u003e ~/.ssh/authorized_keys"}],"source_content_type":"text/x-sh","patch_set":23,"id":"9a89bdaa_b2e4e13b","line":64,"in_reply_to":"fa7ab95a_654b805a","updated":"2016-09-03 14:03:55.000000000","message":"Done","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"}],"tests/setup_functional_test.sh":[{"author":{"_account_id":11317,"name":"Eran Rom","email":"eran@itsonlyme.name","username":"eranr"},"change_message_id":"da4661eb82e056a9fef8edde45921aa1b0ff7be4","unresolved":false,"context_lines":[{"line_number":1,"context_line":"#!/bin/bash"},{"line_number":2,"context_line":"./s2aio.sh jenkins host"}],"source_content_type":"text/x-sh","patch_set":23,"id":"1ac06dbe_f2841ab2","line":2,"updated":"2016-08-30 08:41:56.000000000","message":"I would leave this as host for now, but if you think of good reasons why to change to docker for jenkins lets discuss.","commit_id":"2ca3306179fe5ff50fd475e796d0a4dfc470232c"}]}
