Skip to content

Commit eb6cfb5

Browse files
authored
Merge pull request #441 from Paraphraser/20211114-nextcloud-backup-doco-master
20211114 NextCloud documentation - backup/restore - simplified commands
2 parents 026febd + ce27341 commit eb6cfb5

File tree

1 file changed

+23
-24
lines changed

1 file changed

+23
-24
lines changed

docs/Containers/NextCloud.md

Lines changed: 23 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -138,41 +138,41 @@ The passwords need to be set before you bring up the Nextcloud service for the f
138138

139139
8. Create an administrator account and then click "Finish Setup".
140140

141-
9. There is a long delay. And then you get an error:
141+
9. There is a long delay. In most cases, the "Recommended apps" screen appears and you can ignored the instructions in this section. However, if you see the following error:
142142

143143
![Mal-formed URL](./images/nextcloud-malformedurl.png)
144+
145+
then you should:
144146

145-
If you examine the contents of your browser's URL bar, you will find:
147+
* Examine the contents of your browser's URL bar. If you see this pattern:
146148

147-
```
148-
http://localhost/index.php/core/apps/recommended
149-
```
150-
151-
That is **clearly** wrong and it is probably a bug in Nextcloud.
152-
153-
10. 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:
149+
```
150+
http://localhost/index.php/core/apps/recommended
151+
```
154152

155-
* `http://192.168.203.200:9321/index.php/core/apps/recommended`
156-
* `http://myrpi.mydomain.com:9321/index.php/core/apps/recommended`
157-
* `http://myrpi:9321/index.php/core/apps/recommended`
153+
* 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:
158154

159-
Note:
155+
* `http://192.168.203.200:9321/index.php/core/apps/recommended`
156+
* `http://myrpi.mydomain.com:9321/index.php/core/apps/recommended`
157+
* `http://myrpi:9321/index.php/core/apps/recommended`
160158

161-
* This seems to be the only time Nextcloud misbehaves and forces `localhost` into a URL.
159+
Note:
160+
161+
* This seems to be the only time Nextcloud misbehaves and forces `localhost` into a URL.
162162

163-
11. After a delay, you will see the "Recommended apps" screen with a spinner moving down the list of apps as they are loaded:
163+
10. The "Recommended apps" screen appears. A spinner moves down the list of apps as they are loaded:
164164

165165
![Recommended Apps](./images/nextcloud-recommendedapps.png)
166166

167167
Wait for the loading to complete.
168168

169-
12. Eventually, the dashboard will appear. Then the dashboard will be obscured by the "Nextcloud Hub" floating window:
169+
11. Eventually, the dashboard will appear. Then the dashboard will be obscured by the "Nextcloud Hub" floating window:
170170

171171
![Post-initialisation](./images/nextcloud-postinitialisation.png)
172172

173173
Hover your mouse to the right of the floating window and keep clicking on the right-arrow button until you reach the last screen, then click "Start using Nextcloud".
174174

175-
13. Congratulations. Your IOTstack implementation of Nextcloud is ready to roll:
175+
12. Congratulations. Your IOTstack implementation of Nextcloud is ready to roll:
176176

177177
![Dashboard](./images/nextcloud-dashboard.png)
178178

@@ -304,26 +304,25 @@ If you want to take a backup, something like the following will get the job done
304304
$ cd ~/IOTstack
305305
$ BACKUP_TAR_GZ=$PWD/backups/$(date +"%Y-%m-%d_%H%M").$HOSTNAME.nextcloud-backup.tar.gz
306306
$ touch "$BACKUP_TAR_GZ"
307-
$ docker-compose stop nextcloud nextcloud_db
308-
$ docker-compose rm -f nextcloud nextcloud_db
307+
$ docker-compose rm --force --stop -v nextcloud nextcloud_db
309308
$ sudo tar -czf "$BACKUP_TAR_GZ" -C "./volumes/nextcloud" .
310-
$ docker-compose up -d
309+
$ docker-compose up -d nextcloud
311310
```
312311

313-
Note:
312+
Notes:
314313

315314
* A *baseline* backup takes over 400MB and about 2 minutes. Once you start adding your own data, it will take even more time and storage.
315+
* The `up` of the NextCloud container implies the `up` of the Nextcloud_DB container.
316316

317317
To restore, you first need to identify the name of the backup file by looking in the `backups` directory. Then:
318318

319319
```
320320
$ cd ~/IOTstack
321321
$ RESTORE_TAR_GZ=$PWD/backups/2021-06-12_1321.sec-dev.nextcloud-backup.tar.gz
322-
$ docker-compose stop nextcloud nextcloud_db
323-
$ docker-compose rm -f nextcloud nextcloud_db
322+
$ docker-compose rm --force --stop -v nextcloud nextcloud_db
324323
$ sudo rm -rf ./volumes/nextcloud/*
325324
$ sudo tar -x --same-owner -z -f "$RESTORE_TAR_GZ" -C "./volumes/nextcloud"
326-
$ docker-compose up -d
325+
$ docker-compose up -d nextcloud
327326
```
328327

329328
If you are running from an SD card, it would be a good idea to mount an external drive to store the data. Something like:

0 commit comments

Comments
 (0)