Fixed install process (#1)
Co-authored-by: muppeth <muppeth@disroot.org> Reviewed-on: #1 Co-authored-by: muppeth <muppeth@no-reply@disroot.org> Co-committed-by: muppeth <muppeth@no-reply@disroot.org>
This commit is contained in:
parent
3227a49235
commit
56d46d6861
|
@ -12,6 +12,11 @@ akaunting_db_port: '3306'
|
|||
akaunting_db_user: 'admin'
|
||||
akaunting_db_passwd: 'changeme'
|
||||
|
||||
akaunting_company_name: 'Meta'
|
||||
akaunting_admin_email: 'admin@example.lan'
|
||||
akaunting_admin_passwd: 'changeme'
|
||||
|
||||
|
||||
akaunting_pkgs: '{{ php_pkgs }}'
|
||||
|
||||
#PHP Vars
|
||||
|
|
|
@ -20,3 +20,16 @@
|
|||
group: '{{ akaunting_group }}'
|
||||
remote_src: yes
|
||||
when: akaunting_installed.stat.exists == false
|
||||
|
||||
- name: '[Install] - Check if database is deployed'
|
||||
shell: "php {{ akaunting_app_dir }}/artisan migrate:status"
|
||||
become: yes
|
||||
become_user: "{{ akaunting_user }}"
|
||||
register: akaunting_db_installed
|
||||
ignore_errors: yes
|
||||
|
||||
- name: '[Install] - Install akaunting'
|
||||
shell: "php {{ akaunting_app_dir }}/artisan install --db-host {{ akaunting_db_host }} --db-name {{akaunting_db_name }} --db-username {{ akaunting_db_user }} --db-password {{ akaunting_db_passwd }} --company-name {{ akaunting_company_name }} --admin-email {{ akaunting_admin_email }} --admin-password {{ akaunting_admin_passwd }} -q"
|
||||
become: yes
|
||||
become_user: "{{ akaunting_user }}"
|
||||
when: akaunting_db_installed.rc == 1
|
||||
|
|
Loading…
Reference in New Issue