-
Notifications
You must be signed in to change notification settings - Fork 5
/
main.yml
174 lines (154 loc) · 5.93 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
---
nextcloud_enable: true
# Set this to 'no' to completely disable the role
# Installation {{{
nextcloud_version: 17
# The major nextcloud version to install. You can use this to upgrade to a new
# major version as well. Even if you set 'nextcloud_download_url' manually (see
# next option), 'nextcloud_version' should be set as it is also used to
# correctly install the apps.
nextcloud_download_url: >-
{%- if nextcloud_version > 0 -%}
https://download.nextcloud.com/server/releases/latest-{{
nextcloud_version }}.zip
{%- else -%}
https://download.nextcloud.com/server/releases/latest.zip
{%- endif -%}
# The url to download nextcloud from. Currently only the latest stable version
# is supported by the role.
nextcloud_installation_dir: '/var/www/html/nextcloud/'
# Where to extract nextcloud files. This is the directory where the web server
# will load nextcloud from.
nextcloud_data_dir: "{{ nextcloud_installation_dir }}/data"
# Path to nextcloud user data directory.
nextcloud_file_owner: 'www-data'
# The user that will own nextcloud files.
nextcloud_database:
backend: mysql
# The database server that will be used. It should be already installed and
# the database should already exist. For 'mariadb', set this to 'mysql'.
name: nextcloud
# The name of the database nextcloud will use. It should already exist on the
# system.
user: nextcloud
# The database user that nextcloud will use to access the database. The user
# should already exist in the database backend (together with their password).
pass: ''
# The database user's password. This variable should not be empty.
host: localhost
# The database host
port: 3306
# The port the db server listens on
prefix: oc_
# Prefix for the nextcloud tables in the database.
# }}}
# Core configuration {{{
# TODO make this part of nextcloud_config_system
nextcloud_enable_pretty_urls: true
# Set to yes to enable urls of the form https://example.org/calendar replacing
# https://example.org/nextcloud/index.php/s/Sv1b7krAUqmF8QQ.
# TODO make this part of nextcloud_config_system
nextcloud_urls:
- https://localhost:80/folder
# This is a list of urls where your nextcloud installation should be accessible.
# You would normally need only one. If you specify more than one, the first one
# will be as the "main" one, for pretty urls, etc.
# }}}
# occ {{{
nextcloud_occ_make_executable: true
# Whether to make the occ tool executable (to avoid using `php occ ...` and use
# `occ ...` directly).
nextcloud_occ_system_command: true
# Whether to create a /usr/bin/occ executable script that will allow all users
# of the system to run `occ` (with completion if `nextcloud_occ_completions` is
# enabled). The script calls sudo to run `occ` as the nextcloud user.
nextcloud_occ_completions: true
# Whether to enable bash completion for the occ tool
# }}}
# Users {{{
nextcloud_admin_user: admin
# The name of the admin user
nextcloud_admin_pass: ''
# The password of the admin user. This variable should not be empty.
nextcloud_users: []
# The ansible users to create, other than the admin.
# It is a list of hashes. Eg
#
# nextcloud_users:
# - name: alice
# pass: superstrongnot
# resetpassword: yes # reset the passsword every time the playbook is run
# display_name: Alice B. Charlie
# settings:
# - firstrunwizard:
# show: 0
# - calendar:
# showWeekNr: 'yes'
# app_config:
# ...
#
# App and core configuration happens per user. To find out what config options
# are available, either make the changes manually and then the oc_preferences
# table in your nextcloud database or use the `occ config:list` command on your
# server to get a listing of the current configuration options.
# }}}
# Apps {{{
nextcloud_remove_unknown_apps: false
# Setting to choose whether to remove or keep external apps which have not been
# installed through this role, but manually or via the Nextcloud admin interface
nextcloud_apps: []
# Nextcloud apps to be installed, removed, enabled or disabled
# It is a list of hashes. Eg
#
# nextcloud_apps:
# - name: calendar
# state: enabled
#
# The action can be defined using the app's state, the following states are
# supported:
# - present: The app will be installed, the enabled status will not be changed
# - absent: The app will be removed. Only available for external apps.
# - enabled: The app will be installed if not available yet, and will be
# enabled
# - disabled: The app will be installed if not available yet, and will be
# disabled
#
# Installation and removal is only supported for external apps, apps shipped
# with Nextcloud can only be enabled or disabled. By default, only apps with
# the explicit state `absent` are removed, to remove all apps missing from the
# list, set `nextcloud_remove_unknown_apps: true`.
# Currently, always the latest version available from the App Store is
# installed.
nextcloud_config: {}
# A yaml array with settings of nextcloud apps.
#
# Nextcloud organizes its configuration in two categories:
# - system: this category contains all basic configuration parameters for the
# framework to operate. Its keys are stored in the `config.php` file
# of the instance installation's `config` directory.
# - apps: this category contains settings for the individual apps as well as
# for some core components of the framework (in `core`). These settings
# are stored in the database directly and require a correctly
# configured system to be accessed.
#
# For instance:
# ```
# nextcloud_config:
# apps:
# core:
# backgroundjobs_mode: cron
# system:
# overwrite:
# cli:
# url: "{{ nextcloud_urls[0] | regex_replace(':[0-9]{2,5}', '') }}"
# trusted_domains:
# "{{ nextcloud_urls | map('urlsplit', 'hostname') | list }}"
# htaccess:
# RewriteBase: >-
# /{{ nextcloud_urls[0]
# | regex_replace('/$', '')
# | urlsplit('path')
# | regex_replace('^/')
# }}
# ```
# }}}