Apply prettier formatting

This commit is contained in:
Marty Oehme 2024-06-24 20:36:55 +02:00
parent 6b4c4ccde4
commit c498b3ced8
Signed by: Marty
GPG key ID: EDBF2ED917B2EF6A
76 changed files with 123 additions and 202 deletions

View file

@ -4,13 +4,14 @@ A full office suite and groupware proposition,
though its main draw for most is the file synchronization abilities.
AKA Dropbox replacement.
This software can grow enormous and enormously complicated,
This software can grow enormous and enormously complicated,
this Ansible setup role concentrates on 3 things:
* a stable and secure base setup from the official docker container
* automatic setup of an email pipeline so users can reset passwords and be updated of changes
* the ability to use S3 object storage as the primary way of storing users' files
The rest should be taken care of either automatically,
- a stable and secure base setup from the official docker container
- automatic setup of an email pipeline so users can reset passwords and be updated of changes
- the ability to use S3 object storage as the primary way of storing users' files
The rest should be taken care of either automatically,
or supplied after the fact (if using different plugins or similar).
## Defaults
@ -32,7 +33,7 @@ nextcloud_version: fpm
nextcloud_db_version: 12
```
The docker image version to be used in stack creation.
The docker image version to be used in stack creation.
The role sets up the `php-fpm` version of the official Nextcloud image.
That means, Caddy is used in front as the server which presents all pages
and access to files, the Nextcloud image itself only serves as the PHP data store.
@ -41,17 +42,17 @@ If changing the version to one relying on Nextcloud's in-built Apache server,
take care to change where the upstream proxy is pointing to since the Caddy server in front loses its meaning.
The second variable points to the docker image that should be used for the PostgreSQL database,
with 12 pre-filled as default.
with 12 pre-filled as default.
You can put this to latest, but should take care to migrate the database correctly when an update rolls around,
or it *will* destroy your data at some point.
or it _will_ destroy your data at some point.
Generally, it seems easier to pin this to a specific version and then only update manually.
```yml
subdomain_alias: files
```
If the deployed container should be served over a uri that is not the stack name.
By default, it will be set to `files.yourdomain.com` -
If the deployed container should be served over a uri that is not the stack name.
By default, it will be set to `files.yourdomain.com` -
if this option is not set it will be served on `nextcloud.yourdomain.com` instead.
If you change or delete this, you should also change what `nextcloud_trusted_domains` points to.
@ -66,7 +67,7 @@ nextcloud_db_password: secretnextcloud
```
Sets the default username and password for application and database.
All of these variables are necessary to circumvent the manual installation process
All of these variables are necessary to circumvent the manual installation process
you would usually be faced with on first creating a Nextcloud instance.
Ideally change all of these for your personal setup,
but it is especially important to change the app admin login data since they are what is public facing.
@ -77,7 +78,7 @@ nextcloud_trusted_domains: "{{ subdomain_alias }}.{{ server_domain }}"
The domains that are allowed to access your Nextcloud instance.
Should point to any domains that you want it accessible on,
can be a space-separated list of them.
can be a space-separated list of them.
Take care to include the sub-domain if your are accessing it through one of them.
[Further explanation](https://blog.martyoeh.me/posts/2021-11-18-nextcloud-trusted-domains/).
@ -130,7 +131,6 @@ If your details are correct, Nextcloud should automatically set up S3 as its pri
Be careful if you switch an existing data volume of the Nextcloud image to S3
as you will lose all access to existing files.
The files *should* not be deleted at this point,
The files _should_ not be deleted at this point,
only access will be lost,
but you are playing with fire at this point.

View file

@ -1,5 +1,4 @@
---
# set preferred application version
nextcloud_version: 28-fpm-alpine
# set preferred postgres version
@ -31,7 +30,6 @@ nextcloud_smtp_authtype: LOGIN
# nextcloud_smtp_password: <smtp-password>
nextcloud_smtp_from_address: noreply
nextcloud_smtp_from_domain: "{{ server_domain }}"
# the following block is required *fully* for primary object storage
# nextcloud_s3_host: s3.eu-central-1.wasabisys.com
# nextcloud_s3_bucket: nextcloud

View file

@ -3,7 +3,7 @@
ansible.builtin.file:
path: "{{ nextcloud_upstream_file_dir }}"
state: directory
mode: '0755'
mode: "0755"
become: true
listen: "update nextcloud upstream"
@ -40,7 +40,7 @@
community.docker.docker_container_exec:
container: "{{ caddy_container_id }}"
command: >
curl -X POST -H "Content-Type: application/json" -d @{{ nextcloud_upstream_file_dir }}/upstream.json localhost:2019/config/apps/http/servers/{{ (nextcloud_use_https == True) | ternary(caddy_https_server_name, caddy_http_server_name) }}/routes/0/
curl -X POST -H "Content-Type: application/json" -d @{{ nextcloud_upstream_file_dir }}/upstream.json localhost:2019/config/apps/http/servers/{{ (nextcloud_use_https == True) | ternary(caddy_https_server_name, caddy_http_server_name) }}/routes/0/
become: true
listen: "update nextcloud upstream"
@ -50,4 +50,3 @@
state: absent
become: true
listen: "update nextcloud upstream"

View file

@ -1,5 +1,4 @@
---
galaxy_info:
author: Marty Oehme
description: Installs nextcloud as a docker stack service
@ -7,7 +6,6 @@ galaxy_info:
min_ansible_version: "2.9"
galaxy_tags: []
dependencies:
- docker-swarm
- caddy_id

View file

@ -14,7 +14,7 @@
ansible.builtin.file:
path: "{{ nextcloud_upstream_file_dir }}"
state: directory
mode: '0755'
mode: "0755"
become: true
notify: "update nextcloud upstream"
@ -36,4 +36,3 @@
tags:
- docker-swarm
notify: "update nextcloud upstream"

View file

@ -1,5 +1,4 @@
---
stack_name: nextcloud
stack_image: "nextcloud"