Skip to content

Commit 41854f1

Browse files
committed
develop: nextcloud docs
1 parent dc0579e commit 41854f1

File tree

2 files changed

+29
-1
lines changed

2 files changed

+29
-1
lines changed

docs/modules/nixos/nextcloud.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,31 @@ nix-shell -p mkpasswd --run 'mkpasswd -sm bcrypt'
4343
Installing apps via the web interface is disabled. You have to use `services.nextcloud.extraApps`.
4444

4545
Configuring them works as usual in the web interface.
46+
47+
## Maintenance
48+
49+
### Admin CLI
50+
51+
Use Nextcloud's `occ` command for server operations. On NixOS, it is available under the wrapper script `nextcloud-occ`. Refer to the [Nextcloud docs](https://docs.nextcloud.com/server/latest/admin_manual/occ_command.html) on how to use the `occ` command, especially the [Maintenance commands](https://docs.nextcloud.com/server/latest/admin_manual/occ_command.html#maintenance-commands). Here are some useful commands:
52+
53+
- General housekeeping: `sudo nextcloud-occ maintenance:repair --include-expensive`
54+
55+
### Logging
56+
57+
Nextcloud's logs are handled through systemd. Relevant services are:
58+
59+
- `phpfpm-nextcloud.service`: PHP-FPM processes that run the Nextcloud application code - application-level logs
60+
- `nextcloud-cron.service`: Runs Nextcloud's background jobs and maintenance tasks - cron job execution logs
61+
- `nginx.service`: Web server that handles HTTP requests - access and connection logs
62+
63+
You can check these logs with:
64+
65+
```bash
66+
journalctl -u SERVICE
67+
```
68+
69+
These flags might be useful:
70+
71+
- `-p err`: Show only error-level messages and above
72+
- `-f`: Follow logs in real-time
73+
- `--since today`: Show logs from today onwards

modules/nixos/nextcloud/default.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ in
5050
config = {
5151
adminuser = mkDefault "nextcloud";
5252
adminpassFile = mkDefault "/etc/secrets/nextcloud-initial-admin-pass";
53-
dbtype = mkDefault "sqlite";
53+
dbtype = mkDefault "sqlite"; # TODO: switch to postgresql
5454
};
5555
configureRedis = mkDefault true;
5656
extraAppsEnable = mkDefault true;

0 commit comments

Comments
 (0)