Skip to content

Commit

Permalink
Patching ALLOWED_HOSTS in settings.py
Browse files Browse the repository at this point in the history
  • Loading branch information
kalxas committed Jan 4, 2017
1 parent 1d1cedb commit 4ee5603
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tasks/geonode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,10 @@
- name: copy the local_settings.py file in place
template: src=local_settings.py.j2 dest={{app_code_dir}}/{{app_name}}/{{app_name}}/local_settings.py

- name: patch the settings.py file in place
shell: sed -i -e "s/ALLOWED_HOSTS = os.getenv('ALLOWED_HOSTS', \['localhost', \])/ALLOWED_HOSTS = os.getenv('ALLOWED_HOSTS', \['localhost', '{{ server_name }}'\])/g" {{app_code_dir}}/{{app_name}}/{{app_name}}/settings.py
when: github_user != "GeoNode"

- name: check if requirements file exists
stat: path={{app_code_dir}}/{{app_name}}/requirements.txt
register: requirements_file
Expand Down

0 comments on commit 4ee5603

Please sign in to comment.