fmartingr
/
shelfzilla
Archived
1
0
Fork 0

fix lineinfile of python post task

This commit is contained in:
Juan Manuel Parrilla 2014-11-16 16:32:32 +01:00
parent 3ad048e5b8
commit a077911077
3 changed files with 14 additions and 12 deletions

View File

@ -1,3 +1,3 @@
shelfzilla_base_path: /opt/shelfzilla
shelfzillla_config_file: "{{ shelfzilla_base_path }}/shelfzilla.toml"
shelfzillla_config_file: 'shelfzilla.toml'
system_init_path: /etc/init.d

View File

@ -6,7 +6,7 @@
- lineinfile: dest="{{shelfzilla_base_path}}/shelfzilla/settings/configfile.py"
regexp="^(.*)os\.environ\[\'APP\_CONFIGFILE\'\](.*)$"
state=present
line="\'\1{{ shelfzillla_config_file }}\2\'"
line="\1\'{{ shelfzilla_base_path }}/{{ shelfzillla_config_file }}\'\2"
backrefs=yes
sudo: yes

View File

@ -70,19 +70,21 @@
- stat: path="{{ logfile }}"
register: st
- name: Create Logfile
file: path="{{ logfile }}"
owner=root
group=root
mode=0666
state=file
sudo: yes
when: not st.stat.exists
- name: Create Static base path
- name: Create LogPath
file: path="{{ logpath }}"
owner=root
group=root
mode=0755
state=directory
sudo: yes
- name: Create Logfile
file: path="{{ logfile }}"
owner=root
group=root
mode=0666
state=touch
sudo: yes
when: not st.stat.exists