App installation and updater.
This commit is contained in:
parent
31be0f1fc7
commit
0a32f99552
1 changed files with 21 additions and 24 deletions
|
@ -178,30 +178,6 @@
|
||||||
warn: False
|
warn: False
|
||||||
when: not nextcloud.stat.exists
|
when: not nextcloud.stat.exists
|
||||||
|
|
||||||
|
|
||||||
## app installations:
|
|
||||||
- name: check if calendar app is installed
|
|
||||||
stat: path="{{ nc_dir }}/apps/calendar"
|
|
||||||
register: calendar
|
|
||||||
|
|
||||||
- name: install calendar app
|
|
||||||
command: sudo -u www-data php ./occ app:install calendar
|
|
||||||
args:
|
|
||||||
chdir: "{{ nc_dir }}"
|
|
||||||
warn: False
|
|
||||||
when: not calendar.stat.exists
|
|
||||||
|
|
||||||
- name: check if notes app is installed
|
|
||||||
stat: path="{{ nc_dir }}/apps/notes"
|
|
||||||
register: notes
|
|
||||||
|
|
||||||
- name: install notes app
|
|
||||||
command: sudo -u www-data php ./occ app:install notes
|
|
||||||
args:
|
|
||||||
chdir: "{{ nc_dir }}"
|
|
||||||
warn: False
|
|
||||||
when: not notes.stat.exists
|
|
||||||
|
|
||||||
## nextcloudcron
|
## nextcloudcron
|
||||||
- name: provide nextcloudcron.service and .timer
|
- name: provide nextcloudcron.service and .timer
|
||||||
copy:
|
copy:
|
||||||
|
@ -220,6 +196,27 @@
|
||||||
warn: False
|
warn: False
|
||||||
when: nextcloudcron.changed
|
when: nextcloudcron.changed
|
||||||
|
|
||||||
|
- name: check/run upgrade
|
||||||
|
command: sudo -u www-data php updater.phar --no-interaction
|
||||||
|
args:
|
||||||
|
chdir: "{{ nc_dir }}/updater"
|
||||||
|
warn: False
|
||||||
|
register: cmd_result
|
||||||
|
changed_when: cmd_result.stdout is not search('Nothing to do.')
|
||||||
|
|
||||||
|
### app installations:
|
||||||
|
- name: install extra apps
|
||||||
|
command: "sudo -u www-data php ./occ app:install {{ item }}"
|
||||||
|
args:
|
||||||
|
chdir: "{{ nc_dir }}"
|
||||||
|
warn: False
|
||||||
|
with_items:
|
||||||
|
- calendar
|
||||||
|
- notes
|
||||||
|
register: cmd_result
|
||||||
|
changed_when: cmd_result.stdout is not search('already installed')
|
||||||
|
failed_when: cmd_result.stdout is not search('already installed') and cmd_result.rc != 0
|
||||||
|
|
||||||
|
|
||||||
## ToDo kerberox integration:
|
## ToDo kerberox integration:
|
||||||
# sudo -u www-data php ./occ app:enable user_ldap
|
# sudo -u www-data php ./occ app:enable user_ldap
|
||||||
|
|
Loading…
Add table
Reference in a new issue