Compare commits

...

2 commits

View file

@ -15,7 +15,9 @@ This service requires the following other services:
## Configuration
To enable this service, add the following configuration to your `vars.yml` file and re-run the [installation](../installing.md) process:
To enable this service, add the following configuration to your `vars.yml` file. This is a minimal example. See also the [Optional Configuration](#optional-configuration) sections below.
Then proceed with the [Installation](#installation) as described below, noting that it includes pre-install and post-install steps.
```yaml
########################################################################
@ -29,7 +31,10 @@ nextcloud_enabled: true
nextcloud_hostname: mash.example.com
nextcloud_path_prefix: /nextcloud
# KeyDB configuration, as described below
nextcloud_initial_admin_username: admin # or a name if using personal accounts for admin
nextcloud_initial_admin_password: ''
# Optional configuration, as described below
########################################################################
# #
@ -42,6 +47,38 @@ In the example configuration above, we configure the service to be hosted at `ht
You can remove the `nextcloud_path_prefix` variable definition, to make it default to `/`, so that the service is served at `https://mash.example.com/`.
You can choose any username/password for the initial account. This account will have [super administrator](https://docs.nextcloud.com/server/30/admin_manual/configuration_user/user_configuration.html#granting-administrator-privileges-to-a-user) privileges, by being a member of the `admin` group, but is not otherwise special or unique.
## Installation
Installation of Nextcloud requires two or three steps.
### Pre-Install
If you've decided to install a dedicated KeyDB instance for Nextcloud, make sure to first do [installation](../installing.md) for the supplementary inventory host (e.g. `nextcloud.example.com-deps`), before running installation for the main one (e.g. `nextcloud.example.com`).
### Main Install and Start Services
Run the [installation](../installing.md) for the main nextcloud host, e.g. `just run-tags install-all,start`.
Ensure Nextcloud and all services it depends on are installed and started.
### Post-Install
After the main installation, and services are running, you need to run a post-install step before Nextcloud will be available to use.
Run the post-install step: `just run-tags post-install-nextcloud` (or `post-install-all`).
This post-install step:
- runs the Nextcloud [initial installation](https://docs.nextcloud.com/server/latest/admin_manual/installation/command_line_installation.html) `occ maintenance:install`, if it hasn't yet run.
- adjusts the configuration of URL paths, trusted reverse-proxies, etc.
- configures Nextcloud settings including those you define in `nextcloud_config_additional_parameters`.
Run it again after making any changes.
## Optional Configuration
### KeyDB
KeyDB can **optionally** be enabled to improve Nextcloud performance.
@ -228,21 +265,6 @@ To enable [Samba](https://www.samba.org/) external Windows fileshares using [smb
nextcloud_container_image_customizations_samba_enabled: true
```
## Installation
If you've decided to install a dedicated KeyDB instance for Nextcloud, make sure to first do [installation](../installing.md) for the supplementary inventory host (e.g. `nextcloud.example.com-deps`), before running installation for the main one (e.g. `nextcloud.example.com`).
## Usage
After [installation](../installing.md), you should follow Nextcloud's setup wizard at the URL you've chosen.
You can choose any username/password for your account.
In **Storage & database**, you should choose PostgreSQL (changing the default **SQLite** choice), with the credentials you see after running `just run-tags print-nextcloud-db-credentials`
Once you've fully installed Nextcloud, you'd better adjust its default configuration (URL paths, trusted reverse-proxies, etc.) by running: `just run-tags adjust-nextcloud-config`
## Recommended other services
### Collabora Online
@ -283,7 +305,7 @@ then install Nextcloud (or rerun the playbook if already installed).
Next, from the Settings/Application menu in your Nextcloud instance install the preview generator app (https://apps.nextcloud.com/apps/previewgenerator).
After the application is installed run `just run-tags adjust-nextcloud-config` that will start the original preview-generation and when finished, enables the periodic generation of new images.
After the application is installed run `just run-tags post-install-nextcloud` that will start the original preview-generation and when finished, enables the periodic generation of new images.
The original generation may take a long time, but a continuous prompt is presented by ansible as some visual feedback (it is being run as an async task), however it will timeout after approximately 27 hours.
@ -295,7 +317,7 @@ If it takes more time to run than a day, you may want to start it from the host
/usr/bin/env docker exec mash-nextcloud-server php /var/www/html/occ preview:generate-all
```
Also, please note: every time Nextcloud version is updated, you should rerun: `just run-tags adjust-nextcloud-config`.
Also, please note: every time Nextcloud version is updated, you should rerun: `just run-tags post-install-nextcloud`.
Other supported variables: