You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/Containers/NextCloud.md
+22-69Lines changed: 22 additions & 69 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,12 +10,14 @@ nextcloud:
10
10
image: nextcloud
11
11
restart: unless-stopped
12
12
environment:
13
+
- TZ=${TZ:-Etc/UTC}
13
14
- MYSQL_HOST=nextcloud_db
14
-
- MYSQL_PASSWORD=«user_password»
15
+
- MYSQL_PASSWORD=%randomMySqlPassword%
15
16
- MYSQL_DATABASE=nextcloud
16
17
- MYSQL_USER=nextcloud
17
18
ports:
18
19
- "9321:80"
20
+
- "9343:443"
19
21
volumes:
20
22
- ./volumes/nextcloud/html:/var/www/html
21
23
depends_on:
@@ -29,11 +31,11 @@ nextcloud_db:
29
31
build: ./.templates/mariadb/.
30
32
restart: unless-stopped
31
33
environment:
32
-
- TZ=Etc/UTC
34
+
- TZ=${TZ:-Etc/UTC}
33
35
- PUID=1000
34
36
- PGID=1000
35
-
- MYSQL_ROOT_PASSWORD=«root_password»
36
-
- MYSQL_PASSWORD=«user_password»
37
+
- MYSQL_ROOT_PASSWORD=%randomPassword%
38
+
- MYSQL_PASSWORD=%randomMySqlPassword%
37
39
- MYSQL_DATABASE=nextcloud
38
40
- MYSQL_USER=nextcloud
39
41
volumes:
@@ -106,86 +108,33 @@ The passwords need to be set before you bring up the Nextcloud service for the f
106
108
$ docker logs nextcloud
107
109
```
108
110
109
-
6.If you want to be sure Nextcloud gets set up correctly, it is best to perform the remaining steps from a **different** computer.
111
+
6.On a computer that is **not** the device running Nextcloud, launch a browser and point to the device running Nextcloud using your chosen connection method. Examples:
110
112
111
-
That means you need to decide how that **other** computer will refer to your Raspberry Pi running Nextcloud. Your choices are:
112
-
113
-
* the IP address of your Raspberry Pi – eg `192.168.203.200`
114
-
* your Raspberry Pi's fully-qualified domain name – eg `myrpi.mydomain.com`
115
-
* your Raspberry Pi's host name – eg `myrpi`
116
-
117
-
Key points:
118
-
119
-
* You **can't** use a multicast domain name (eg `myrpi.local`). An mDNS name will not work until Nextcloud has been initialised!
120
-
* Once you have picked a connection method, **STICK TO IT**.
121
-
* You are only stuck with this restriction until Nextcloud has been initialised. You **can** (and should) fix it later by completing the steps in ["Access through untrusted domain"](#untrustedDomain).
122
-
123
-
7. On a computer that is **not** the Raspberry Pi running Nextcloud, launch a browser and point to the Raspberry Pi running Nextcloud using your chosen connection method. Examples:
8. Create an administrator account and then click "Install".
148
-
149
-
9. There is a long delay. In most cases, the "Recommended apps" screen appears and you can ignore the instructions in this step. However, if your browser returns a "Not Found" error like the following:
* Examine the contents of your browser's URL bar. If you see this pattern:
156
-
157
-
```
158
-
http://localhost/index.php/core/apps/recommended
159
-
```
160
-
161
-
* Edit the URL to replace `localhost` with what it *should* be, which will be **one** of the following patterns, depending on which method you chose to access Nextcloud:
Keep clicking on the right-arrow button until you reach the last screen, then click "Start using Nextcloud".
182
-
183
-
12. Congratulations. Your IOTstack implementation of Nextcloud is ready to roll:
130
+
9. Congratulations. Your IOTstack implementation of Nextcloud is ready to roll:
184
131
185
132

186
133
187
134
## "Access through untrusted domain" { #untrustedDomain }
188
135
136
+
> The information in this section *may* be out of date. Recent tests suggest it is no longer necessary to edit the `trusted_domains` list in `config.php`. This section is being left here so you will know what to do if you encounter the problem.
137
+
189
138
During Nextcloud initialisation you had to choose between an IP address, a domain name or a host name. Now that Nextcloud is running, you have the opportunity to expand your connection options.
190
139
191
140
> If you are reading this because you are staring at an "access through untrusted domain" message then you have come to the right place.
@@ -255,6 +204,8 @@ See also:
255
204
256
205
### Using a DNS alias for your Nextcloud service { #dnsAlias }
257
206
207
+
> The information in this section *may* be out of date. Recent tests suggest it is no longer necessary to add a `hostname` clause to your `docker-compose.yml` to silence warnings when using DNS aliases to reach your NextCloud service. This section is being left here so you will know what to do if you encounter the problem.
208
+
258
209
The examples above include using a DNS alias (a CNAME record) for your Nextcloud service. If you decide to do that, you may see this warning in the log:
259
210
260
211
```
@@ -271,6 +222,8 @@ You can silence the warning by editing the Nextcloud service definition in `dock
271
222
272
223
Nextcloud traffic is not encrypted. Do **not** expose it to the web by opening a port on your home router. Instead, use a VPN like Wireguard to provide secure access to your home network, and let your remote clients access Nextcloud over the VPN tunnel.
273
224
225
+
The IOTstack service definition for NextCloud reserves port 9343 for HTTPS access but leaves it as an exercise for the reader to figure out how to make it work. You may get some guidance [here](https://youtu.be/qlcVx-k-02E?si=qtVNFAvSB8w202Jh).
226
+
274
227
## Container health check { #healthCheck }
275
228
276
229
A script , or "agent", to assess the health of the MariaDB container has been added to the *local image* via the *Dockerfile*. In other words, the script is specific to IOTstack.
0 commit comments