Commit 006db1e6 by Feanil Patel

'vars' var doesn't work anymore.

Don't override the versions is server-vars.yml.
parent 2450616d
......@@ -34,17 +34,9 @@
dest={{ COMMON_CFG_DIR }}/playbooks
state=link
- name: dump all vars to yaml
template: src=dumpall.yml.j2 dest={{ edx_ansible_var_file }} mode=0600
when: EDX_ANSIBLE_DUMP_VARS
- name: create symlink for config file
file: >
src={{ edx_ansible_var_file }}
dest={{ COMMON_CFG_DIR }}/{{ edx_ansible_var_file|basename }}
state=link
when: EDX_ANSIBLE_DUMP_VARS
- name: clean up var file, removing all version vars and internal ansible vars (anything not caps)
shell: python -c "import yaml; y=yaml.load(open('{{ edx_ansible_var_file }}')); f=open('{{ edx_ansible_var_file }}', 'wb'); f.write(yaml.safe_dump({key:value for key,value in y.iteritems() if key.isupper()}, default_flow_style=False)); f.close();"
when: EDX_ANSIBLE_DUMP_VARS
......@@ -133,6 +133,7 @@ ora_version: $ora_version
ease_version: $ease_version
certs_version: $certs_version
discern_version: $discern_version
configuration_version: $configuration_version
EDXAPP_STATIC_URL_BASE: $static_url_base
EDXAPP_LMS_NGINX_PORT: 80
EDXAPP_LMS_PREVIEW_NGINX_PORT: 80
......@@ -259,8 +260,12 @@ fi
# deploy the edx_ansible role
run_ansible edx_ansible.yml -i "${deploy_host}," $extra_var_arg --user ubuntu
cat $extra_vars_file | grep -v "_version" > ${extra_vars_file}_clean
cat ${extra_vars_file}_clean
scp ${extra_vars_file}_clean ubuntu@${deploy_host}:/edx/app/edx_ansible/server-vars.yml
# set the hostname
run_ansible set_hostname.yml -i "${deploy_host}," -e hostname_fqdn=${deploy_host} --user ubuntu
rm -f "$extra_vars_file"
rm -f ${extra_vars_file}_clean
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment