2
0
mirror of https://github.com/frappe/bench.git synced 2025-01-10 17:24:41 +00:00
bench/playbooks/develop/includes/setup_erpnext.yml
Ameya Shenoy 036b4e4b33
Fixed playbook to be compatible with Mariadb 10.2
- linked mysql.sock file mysql.pid file for compatibility with MaraiDB 10.2
2018-01-18 03:10:26 +05:30

44 lines
1.2 KiB
YAML

---
- name: Check if ERPNext App exists
stat: path="{{ bench_path }}/apps/erpnext"
register: app
- name: get erpnext
command: bench get-app erpnext https://github.com/frappe/erpnext --branch {{ branch }}
args:
creates: "{{ bench_path }}/apps/erpnext"
chdir: "{{ bench_path }}"
when: not app.stat.exists
- name: Check whether a site called site1.local exists
stat: path="{{ bench_path }}/sites/site1.local"
register: site_folder
- name: Link mysql.sock file for MariaDB
file:
src: "/var/lib/mysql/mysql.sock"
dest: "/var/run/mysqld/mysqld.sock"
state: link
become: yes
- name: Link mysql.pid file for MariaDB
file:
src: "/var/lib/mysql/mysql.pid"
dest: "/var/run/mysqld/mysqld.pid"
state: link
become: yes
- name: create a new default site
command: bench new-site site1.local --admin-password {{ admin_password }} --mariadb-root-password {{ mysql_root_password }}
args:
chdir: "{{ bench_path }}"
when: not site_folder.stat.exists
become: yes
become_user: frappe
- name: install erpnext to default site
command: bench --site site1.local install-app erpnext
args:
chdir: "{{ bench_path }}"