Implement direct download during installation.
This commit is contained in:
parent
456f5c9870
commit
8c72a4bec7
2 changed files with 35 additions and 3 deletions
|
@ -12,6 +12,10 @@
|
||||||
DNS: "192.168.2.1"
|
DNS: "192.168.2.1"
|
||||||
ddns_domain: "something.ddnss.de"
|
ddns_domain: "something.ddnss.de"
|
||||||
ddns_updkey: "138638.some.key.here.635620"
|
ddns_updkey: "138638.some.key.here.635620"
|
||||||
|
## 'nc_download' and 'nc_checksum' are only
|
||||||
|
## used for ansible-pull during installation:
|
||||||
|
nc_download: "https://download.nextcloud.com/server/releases/latest.tar.bz2"
|
||||||
|
nc_checksum: "sha256:194095a5586d84040bc455f77b8aa6c80f9a6a6dd713c9aebdad046713d4267b"
|
||||||
nc_apps:
|
nc_apps:
|
||||||
- calendar
|
- calendar
|
||||||
- notes
|
- notes
|
||||||
|
|
|
@ -16,7 +16,9 @@
|
||||||
The nextcloud archive nextcloud.tar.bz2 is not available.
|
The nextcloud archive nextcloud.tar.bz2 is not available.
|
||||||
Download the latest stable release from 'nextcloud.com',
|
Download the latest stable release from 'nextcloud.com',
|
||||||
check the signature, rename it and copy it next to 'cloudbox.yml'.
|
check the signature, rename it and copy it next to 'cloudbox.yml'.
|
||||||
when: not nextcloud.stat.exists and not nc_archive.stat.exists
|
when: >
|
||||||
|
not nextcloud.stat.exists and not nc_archive.stat.exists and
|
||||||
|
not run_in_installer|default(false)|bool
|
||||||
|
|
||||||
## We can start with the installation now:
|
## We can start with the installation now:
|
||||||
|
|
||||||
|
@ -136,6 +138,10 @@
|
||||||
group: www-data
|
group: www-data
|
||||||
|
|
||||||
## install nextcloud:
|
## install nextcloud:
|
||||||
|
- name: start mariadb during installation
|
||||||
|
command: /etc/init.d/mysql start
|
||||||
|
when: run_in_installer|default(false)|bool
|
||||||
|
|
||||||
- name: create database with name 'nextcloud'
|
- name: create database with name 'nextcloud'
|
||||||
mysql_db:
|
mysql_db:
|
||||||
login_unix_socket: /var/run/mysqld/mysqld.sock
|
login_unix_socket: /var/run/mysqld/mysqld.sock
|
||||||
|
@ -152,13 +158,29 @@
|
||||||
state: present
|
state: present
|
||||||
when: not nextcloud.stat.exists
|
when: not nextcloud.stat.exists
|
||||||
|
|
||||||
- name: unpack nextcloud archive
|
- name: download nextcloud archive
|
||||||
|
get_url:
|
||||||
|
url: "{{ nc_download }}"
|
||||||
|
dest: /tmp/nextcloud.tar.bz2
|
||||||
|
checksum: "{{ nc_checksum }}"
|
||||||
|
when: run_in_installer|default(false)|bool
|
||||||
|
|
||||||
|
- name: unpack downloaded nextcloud archive
|
||||||
|
unarchive:
|
||||||
|
src: /tmp/nextcloud.tar.bz2
|
||||||
|
dest: "{{ www_root }}"
|
||||||
|
owner: www-data
|
||||||
|
group: www-data
|
||||||
|
remote_src: Yes
|
||||||
|
when: not nextcloud.stat.exists and run_in_installer|default(false)|bool
|
||||||
|
|
||||||
|
- name: unpack provided nextcloud archive
|
||||||
unarchive:
|
unarchive:
|
||||||
src: nextcloud.tar.bz2
|
src: nextcloud.tar.bz2
|
||||||
dest: "{{ www_root }}"
|
dest: "{{ www_root }}"
|
||||||
owner: www-data
|
owner: www-data
|
||||||
group: www-data
|
group: www-data
|
||||||
when: not nextcloud.stat.exists
|
when: not nextcloud.stat.exists and not run_in_installer|default(false)|bool
|
||||||
|
|
||||||
- name: initialize nextcloud
|
- name: initialize nextcloud
|
||||||
command:
|
command:
|
||||||
|
@ -232,6 +254,12 @@
|
||||||
permanent: Yes
|
permanent: Yes
|
||||||
immediate: Yes
|
immediate: Yes
|
||||||
state: enabled
|
state: enabled
|
||||||
|
when: not run_in_installer|default(false)|bool
|
||||||
|
|
||||||
|
- name: allow https in firewalld, offline
|
||||||
|
command: "firewall-offline-cmd --add-service=https"
|
||||||
|
when: run_in_installer|default(false)|bool
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## ToDo kerberox integration:
|
## ToDo kerberox integration:
|
||||||
|
|
Loading…
Add table
Reference in a new issue