# Ubuntu 14.04 and Default Variable not Set

**URL:** <https://forum.ansible.com/t/ubuntu-14-04-and-default-variable-not-set/15430>\
**Category:** Ansible Project\
**Tags:** ubuntu\
**Created:** [June 9, 2014, 7:09pm UTC](https://forum.ansible.com/t/ubuntu-14-04-and-default-variable-not-set/15430 "2014-06-09T19:09:57Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ray\_Hooker](https://avatars.discourse-cdn.com/v4/letter/r/edb3f5/32.png) [@Ray\_Hooker](https://forum.ansible.com/u/Ray_Hooker)\
**Post date:** [June 9, 2014, 7:09pm UTC](https://forum.ansible.com/t/ubuntu-14-04-and-default-variable-not-set/15430/1 "2014-06-09T19:09:57Z")

</div>

I am trying to debug a problem with installing OpenEdX on Ubuntu 14.04. The same set of playbooks work find on Ubuntu 12.04 BTW. A task was failing apparently because the environment variables were not set. The task is using rbenv. The environment is set as follows:

edxapp\_environment:  
LANG: $EDXAPP\_LANG  
NO\_PREREQ\_INSTALL: $EDXAPP\_NO\_PREREQ\_INSTALL  
SKIP\_WS\_MIGRATIONS: 1  
RBENV\_ROOT: $edxapp\_rbenv\_root  
GEM\_HOME: $edxapp\_gem\_root  
GEM\_PATH: $edxapp\_gem\_root  
PATH: $edxapp\_deploy\_path

I did a debug as the first step of the main.yml tasks file for the edxapp role. The output was:

First the debug:

- name: Display edxapp\_env  
debug: msg=“The EDXAPP Env is {{edxapp\_environment}}!”

then the output…

TASK: [edxapp | Display edxapp\_env] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
ok: [localhost] =\> {  
“item”: “”,  
“msg”: “The EDXAPP Env is {‘LANG’: ‘$EDXAPP\_LANG’, ‘SKIP\_WS\_MIGRATIONS’: 1, ‘GEM\_PATH’: ‘$edxapp\_gem\_root’, ‘NO\_PREREQ\_INSTALL’: ‘$EDXAPP\_NO\_PREREQ\_INSTALL’, ‘PATH’: ‘$edxapp\_deploy\_path’, ‘GEM\_HOME’: ‘$edxapp\_gem\_root’, ‘RBENV\_ROOT’: ‘$edxapp\_rbenv\_root’}!”  
}

What is funny is that debug statement for $edxapp\_rbenv\_root shows that it is properly set even though for some reason it does not create the edxapp\_environment variable correctly. \*\*\*\* BTW I did a debug of complex variables before and after edxapp\_environment and they are set correctly.

Any help or suggestions on how to debug this problem would be appreciated.

Ray

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan1](https://avatars.discourse-cdn.com/v4/letter/m/5e9695/32.png) [@Michael\_DeHaan1](https://forum.ansible.com/u/Michael_DeHaan1)\
**Post date:** [June 11, 2014, 6:58pm UTC](https://forum.ansible.com/t/ubuntu-14-04-and-default-variable-not-set/15430/2 "2014-06-11T18:58:43Z")

</div>

$foo variables have not been used in Ansible for some time.

This is an out of date playbook.
