)]}'
{"playbooks/roles/os_keystone/defaults/main.yml":[{"author":{"_account_id":12807,"name":"Steve Lewis (stevelle)","email":"stevelle@gmail.com","username":"stevelle"},"change_message_id":"0084a357b550370d353e4e86341bebf38765129e","unresolved":false,"context_lines":[{"line_number":344,"context_line":"  - ssl-cert"},{"line_number":345,"context_line":"  - xmlsec1"},{"line_number":346,"context_line":""},{"line_number":347,"context_line":"# Cinder packages that must be installed before anything else"},{"line_number":348,"context_line":"keystone_requires_pip_packages:"},{"line_number":349,"context_line":"  - virtualenv"},{"line_number":350,"context_line":"  - python-keystoneclient # Keystoneclient needed to OSA keystone lib"}],"source_content_type":"text/x-yaml","patch_set":7,"id":"7a2fa921_e3b55c31","line":347,"updated":"2015-10-12 19:05:04.000000000","message":"copy paste error? identifies cinder","commit_id":"26b70f3a141cdbab16f42bfcf0cd9f4789586df6"}],"playbooks/roles/os_keystone/tasks/keystone_db_setup.yml":[{"author":{"_account_id":6816,"name":"Jesse Pretorius","email":"jesse@odyssey4.me","username":"jesse-pretorius"},"change_message_id":"9b7d97a7b7deaa524db21a8ec9f15d61b0294140","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    - keystone-db-setup"},{"line_number":48,"context_line":"    - keystone-db-sync"},{"line_number":49,"context_line":"    - keystone-setup"},{"line_number":50,"context_line":"    - cinder-command-bin"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"9a1a9d01_72e4ccab","line":50,"updated":"2015-10-01 18:31:59.000000000","message":"cinder?","commit_id":"02bc441d035e68774a74907af388d1f100bae1d5"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"9faa1f73371839c9500620a5e0c4931441be36a9","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    - keystone-db-setup"},{"line_number":48,"context_line":"    - keystone-db-sync"},{"line_number":49,"context_line":"    - keystone-setup"},{"line_number":50,"context_line":"    - cinder-command-bin"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"9a1a9d01_d76edd95","line":50,"in_reply_to":"9a1a9d01_72e4ccab","updated":"2015-10-01 23:35:48.000000000","message":"c/p fail","commit_id":"02bc441d035e68774a74907af388d1f100bae1d5"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"de627b4b4b74b119a4aa99520a8e9f7b398ad79e","unresolved":false,"context_lines":[{"line_number":40,"context_line":"    - keystone-db-setup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"- name: Perform a Keystone DB sync"},{"line_number":43,"context_line":"  command: \"{{ keystone_bin }}/keystone-manage db_sync\""},{"line_number":44,"context_line":"  sudo: yes"},{"line_number":45,"context_line":"  sudo_user: \"{{ keystone_system_user_name }}\""},{"line_number":46,"context_line":"  tags:"}],"source_content_type":"text/x-yaml","patch_set":12,"id":"5a2ca52d_c6a08293","line":43,"updated":"2015-10-13 14:54:49.000000000","message":"this doesn\u0027t actually execute keystone-manage *from within* the virtualenv, but i\u0027m not sure if that\u0027s what\u0027s expected or required here in all these instances (the system python appears to be used instead).","commit_id":"0f02b7de05865750dd35f229e09359d287c53d5a"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"32900a1f73de337bc5b30972bdea6cfaae459cac","unresolved":false,"context_lines":[{"line_number":40,"context_line":"    - keystone-db-setup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"- name: Perform a Keystone DB sync"},{"line_number":43,"context_line":"  command: \"{{ keystone_bin }}/keystone-manage db_sync\""},{"line_number":44,"context_line":"  sudo: yes"},{"line_number":45,"context_line":"  sudo_user: \"{{ keystone_system_user_name }}\""},{"line_number":46,"context_line":"  tags:"}],"source_content_type":"text/x-yaml","patch_set":12,"id":"5a2ca52d_49ea0c11","line":43,"in_reply_to":"5a2ca52d_834a4aab","updated":"2015-10-14 15:32:35.000000000","message":"Ooh, fancy!","commit_id":"0f02b7de05865750dd35f229e09359d287c53d5a"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"cf72295353029a218bcc8b3502a8fb3c5766744c","unresolved":false,"context_lines":[{"line_number":40,"context_line":"    - keystone-db-setup"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"- name: Perform a Keystone DB sync"},{"line_number":43,"context_line":"  command: \"{{ keystone_bin }}/keystone-manage db_sync\""},{"line_number":44,"context_line":"  sudo: yes"},{"line_number":45,"context_line":"  sudo_user: \"{{ keystone_system_user_name }}\""},{"line_number":46,"context_line":"  tags:"}],"source_content_type":"text/x-yaml","patch_set":12,"id":"5a2ca52d_834a4aab","line":43,"in_reply_to":"5a2ca52d_c6a08293","updated":"2015-10-14 13:14:42.000000000","message":"This is running within the venv and not using the system python. The creation and installation of binaries into the venv result with #! at the top pointing the python path to the venv. If the #! is not used, like in the case of nova, an \"activate_this\" call at the top is used instead which forces  execution using the venv\u0027d python via the prebuilt `activate_this.py` script.\n\nExample from keystone-manage\n``` bash\nhead -n 1 /openstack/venvs/keystone-master/bin/keystone-manage\n#!/openstack/venvs/keystone-master/bin/python2\n```","commit_id":"0f02b7de05865750dd35f229e09359d287c53d5a"}],"playbooks/roles/os_keystone/tasks/keystone_install.yml":[{"author":{"_account_id":6816,"name":"Jesse Pretorius","email":"jesse@odyssey4.me","username":"jesse-pretorius"},"change_message_id":"18f5327fb8872f952530c3ca6c6f3f3afb52edd3","unresolved":false,"context_lines":[{"line_number":65,"context_line":"- name: Install requires pip packages"},{"line_number":66,"context_line":"  pip:"},{"line_number":67,"context_line":"    name: \"{{ item }}\""},{"line_number":68,"context_line":"    state: present"},{"line_number":69,"context_line":"  register: install_packages"},{"line_number":70,"context_line":"  until: install_packages|success"},{"line_number":71,"context_line":"  retries: 5"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_6972584b","line":68,"updated":"2015-10-07 09:27:54.000000000","message":"Add extra_args: \"{{ pip_install_options|default(\u0027\u0027) }}\"","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"b74a2175d7c6a004436e0287e05f932efab2ddd1","unresolved":false,"context_lines":[{"line_number":65,"context_line":"- name: Install requires pip packages"},{"line_number":66,"context_line":"  pip:"},{"line_number":67,"context_line":"    name: \"{{ item }}\""},{"line_number":68,"context_line":"    state: present"},{"line_number":69,"context_line":"  register: install_packages"},{"line_number":70,"context_line":"  until: install_packages|success"},{"line_number":71,"context_line":"  retries: 5"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_4248832d","line":68,"in_reply_to":"7a2fa921_6972584b","updated":"2015-10-07 15:04:04.000000000","message":"this is something we should add here.","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"},{"author":{"_account_id":6816,"name":"Jesse Pretorius","email":"jesse@odyssey4.me","username":"jesse-pretorius"},"change_message_id":"18f5327fb8872f952530c3ca6c6f3f3afb52edd3","unresolved":false,"context_lines":[{"line_number":78,"context_line":"- name: Install pip packages (venv)"},{"line_number":79,"context_line":"  pip:"},{"line_number":80,"context_line":"    name: \"{{ item }}\""},{"line_number":81,"context_line":"    state: present"},{"line_number":82,"context_line":"    virtualenv: \"{{ keystone_venv_bin | dirname }}\""},{"line_number":83,"context_line":"    virtualenv_site_packages: \"no\""},{"line_number":84,"context_line":"  register: install_packages"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_29930051","line":81,"updated":"2015-10-07 09:27:54.000000000","message":"extra_args: \"{{ pip_install_options|default(\u0027\u0027) }}\"","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"b74a2175d7c6a004436e0287e05f932efab2ddd1","unresolved":false,"context_lines":[{"line_number":78,"context_line":"- name: Install pip packages (venv)"},{"line_number":79,"context_line":"  pip:"},{"line_number":80,"context_line":"    name: \"{{ item }}\""},{"line_number":81,"context_line":"    state: present"},{"line_number":82,"context_line":"    virtualenv: \"{{ keystone_venv_bin | dirname }}\""},{"line_number":83,"context_line":"    virtualenv_site_packages: \"no\""},{"line_number":84,"context_line":"  register: install_packages"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_62cb3fa6","line":81,"in_reply_to":"7a2fa921_29930051","updated":"2015-10-07 15:04:04.000000000","message":"This was omitted in this situation because installing into a venv should be only done once. If the deployer wishes to reinstall bits into the venv I\u0027m of the opinion that the venv should be destroyed and recreated.","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"},{"author":{"_account_id":6816,"name":"Jesse Pretorius","email":"jesse@odyssey4.me","username":"jesse-pretorius"},"change_message_id":"737c0c9fb3ba0f23bd7579087eecf58028afc229","unresolved":false,"context_lines":[{"line_number":78,"context_line":"- name: Install pip packages (venv)"},{"line_number":79,"context_line":"  pip:"},{"line_number":80,"context_line":"    name: \"{{ item }}\""},{"line_number":81,"context_line":"    state: present"},{"line_number":82,"context_line":"    virtualenv: \"{{ keystone_venv_bin | dirname }}\""},{"line_number":83,"context_line":"    virtualenv_site_packages: \"no\""},{"line_number":84,"context_line":"  register: install_packages"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_a2907744","line":81,"in_reply_to":"7a2fa921_62cb3fa6","updated":"2015-10-07 15:08:04.000000000","message":"Sure, but there may be a situation where other pip args are useful.","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"},{"author":{"_account_id":6816,"name":"Jesse Pretorius","email":"jesse@odyssey4.me","username":"jesse-pretorius"},"change_message_id":"18f5327fb8872f952530c3ca6c6f3f3afb52edd3","unresolved":false,"context_lines":[{"line_number":91,"context_line":"  tags:"},{"line_number":92,"context_line":"    - keystone-pip-packages"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"- name: Install pip packages"},{"line_number":95,"context_line":"  pip:"},{"line_number":96,"context_line":"    name: \"{{ item }}\""},{"line_number":97,"context_line":"    state: present"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_699b3873","line":94,"updated":"2015-10-07 09:27:54.000000000","message":"Maybe add a suffix here (no venv) or something like that? This is so that when it\u0027s skipped, it\u0027s understandable why that has happened.","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"b74a2175d7c6a004436e0287e05f932efab2ddd1","unresolved":false,"context_lines":[{"line_number":91,"context_line":"  tags:"},{"line_number":92,"context_line":"    - keystone-pip-packages"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"- name: Install pip packages"},{"line_number":95,"context_line":"  pip:"},{"line_number":96,"context_line":"    name: \"{{ item }}\""},{"line_number":97,"context_line":"    state: present"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_c23b339b","line":94,"in_reply_to":"7a2fa921_699b3873","updated":"2015-10-07 15:04:04.000000000","message":"This is a good idea.","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"}],"playbooks/roles/os_keystone/tasks/keystone_post_install.yml":[{"author":{"_account_id":6816,"name":"Jesse Pretorius","email":"jesse@odyssey4.me","username":"jesse-pretorius"},"change_message_id":"18f5327fb8872f952530c3ca6c6f3f3afb52edd3","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  tags:"},{"line_number":74,"context_line":"    - keystone-config"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"- name: Get keystone command path"},{"line_number":77,"context_line":"  command: which keystone"},{"line_number":78,"context_line":"  register: keystone_command_path"},{"line_number":79,"context_line":"  when:"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_69eed8b5","line":76,"updated":"2015-10-07 09:27:54.000000000","message":"Is this not a known path for a venv and non-venv situation? If so, why don\u0027t we rather use a ternary in the defaults instead?","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"b74a2175d7c6a004436e0287e05f932efab2ddd1","unresolved":false,"context_lines":[{"line_number":73,"context_line":"  tags:"},{"line_number":74,"context_line":"    - keystone-config"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"- name: Get keystone command path"},{"line_number":77,"context_line":"  command: which keystone"},{"line_number":78,"context_line":"  register: keystone_command_path"},{"line_number":79,"context_line":"  when:"}],"source_content_type":"text/x-yaml","patch_set":5,"id":"7a2fa921_62a6df11","line":76,"in_reply_to":"7a2fa921_69eed8b5","updated":"2015-10-07 15:04:04.000000000","message":"Its not a known path in all sitiuations. For the venvs we know it and that is why these tasks are skipped however when using the host namespace the path could be, /usr/local/bin, /usr/bin, or /bin.","commit_id":"b3ff9f590ab7f1bc492d06d7fa6be83d5b93298a"}],"playbooks/roles/os_keystone/templates/keystone-wsgi.py.j2":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"de627b4b4b74b119a4aa99520a8e9f7b398ad79e","unresolved":false,"context_lines":[{"line_number":17,"context_line":"{% if keystone_venv_enabled | bool %}"},{"line_number":18,"context_line":"activate_this \u003d os.path.expanduser(\"{{ keystone_venv_bin }}/activate_this.py\")"},{"line_number":19,"context_line":"execfile(activate_this, dict(__file__\u003dactivate_this))"},{"line_number":20,"context_line":"{% endif %}"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"from keystone.server import wsgi as wsgi_server"},{"line_number":23,"context_line":""}],"source_content_type":"text/x-jinja2","patch_set":12,"id":"5a2ca52d_69c85f75","line":20,"updated":"2015-10-13 14:54:49.000000000","message":"It\u0027s not clear to me why you need to do this backwards? i.e. why not use `WSGIPythonHome {{ keystone_venv }}` in the apache config?","commit_id":"0f02b7de05865750dd35f229e09359d287c53d5a"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"cf72295353029a218bcc8b3502a8fb3c5766744c","unresolved":false,"context_lines":[{"line_number":17,"context_line":"{% if keystone_venv_enabled | bool %}"},{"line_number":18,"context_line":"activate_this \u003d os.path.expanduser(\"{{ keystone_venv_bin }}/activate_this.py\")"},{"line_number":19,"context_line":"execfile(activate_this, dict(__file__\u003dactivate_this))"},{"line_number":20,"context_line":"{% endif %}"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"from keystone.server import wsgi as wsgi_server"},{"line_number":23,"context_line":""}],"source_content_type":"text/x-jinja2","patch_set":12,"id":"5a2ca52d_e3577e00","line":20,"in_reply_to":"5a2ca52d_69c85f75","updated":"2015-10-14 13:14:42.000000000","message":"In testing the WSGIPythonHome does not activate nor run within the venv using the local python. I did try setting the WSGIPythonPath however it too did not function within the venv as expected. Running the activate call was the only way I could get it to go. If there\u0027s a better way I\u0027d be happy to do it though. \n\nRE: http://stackoverflow.com/questions/6723494/setting-up-apache-and-python-wsgi-to-use-virtualenv","commit_id":"0f02b7de05865750dd35f229e09359d287c53d5a"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"43087f9ce60f229f5b8408b951289398569f62b5","unresolved":false,"context_lines":[{"line_number":17,"context_line":"{% if keystone_venv_enabled | bool %}"},{"line_number":18,"context_line":"activate_this \u003d os.path.expanduser(\"{{ keystone_venv_bin }}/activate_this.py\")"},{"line_number":19,"context_line":"execfile(activate_this, dict(__file__\u003dactivate_this))"},{"line_number":20,"context_line":"{% endif %}"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"from keystone.server import wsgi as wsgi_server"},{"line_number":23,"context_line":""}],"source_content_type":"text/x-jinja2","patch_set":12,"id":"5a2ca52d_e620ec9d","line":20,"in_reply_to":"5a2ca52d_e3577e00","updated":"2015-10-14 13:19:40.000000000","message":"Also note that using the activate_this call is similar to how some services leverage the venv functionality. In an example of nova this is how they load a venv\n\n\n``` bash\n# head -n 3 /openstack/venvs/nova-master/bin/nova-manage \n#!/usr/bin/env python2.7\n\nimport os; activate_this\u003dos.path.join(os.path.dirname(os.path.realpath(__file__)), \u0027activate_this.py\u0027); exec(compile(open(activate_this).read(), activate_this, \u0027exec\u0027), dict(__file__\u003dactivate_this)); del os, activate_this\n\n\n```","commit_id":"0f02b7de05865750dd35f229e09359d287c53d5a"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"32900a1f73de337bc5b30972bdea6cfaae459cac","unresolved":false,"context_lines":[{"line_number":17,"context_line":"{% if keystone_venv_enabled | bool %}"},{"line_number":18,"context_line":"activate_this \u003d os.path.expanduser(\"{{ keystone_venv_bin }}/activate_this.py\")"},{"line_number":19,"context_line":"execfile(activate_this, dict(__file__\u003dactivate_this))"},{"line_number":20,"context_line":"{% endif %}"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"from keystone.server import wsgi as wsgi_server"},{"line_number":23,"context_line":""}],"source_content_type":"text/x-jinja2","patch_set":12,"id":"5a2ca52d_9cee24b3","line":20,"in_reply_to":"5a2ca52d_e620ec9d","updated":"2015-10-14 15:32:35.000000000","message":"Hmmm.... I don\u0027t think there\u0027s any escaping running in the Python interpreter that mod_wsgi is already running in, but you should be able to control the available site-packages and effectively emulate the venv.\n\nI mostly just found this odd based on my experience running venv\u0027d WSGI apps in not-mod_wsgi, so if this is how you have to do it with mod_wsgi, then so-be-it!","commit_id":"0f02b7de05865750dd35f229e09359d287c53d5a"}]}
