# Nextcloud (ARM64) ``` version: '3.3' services: db: image: yobasystems/alpine-mariadb:latest command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW --innodb-read-only-compressed=OFF # or --transaction-isolation=READ-COMMITTED --binlog-format=ROW --innodb-file-per-table=1 --skip-innodb-read-only-compressed restart: unless-stopped volumes: - /srv/path/NextCloud/database:/var/lib/mysql environment: - MYSQL_ROOT_PASSWORD=rootpass - MYSQL_PASSWORD=dbpass - MYSQL_DATABASE=nextcloud - MYSQL_USER=nextcloud app: image: nextcloud ports: - 8080:80 links: - db volumes: - /srv/path/NextCloud/config:/var/www/html restart: unless-stopped ``` Host is `db` ``` sudo nano /srv/path/NextCloud/config/config/config.php ``` edit `'overwrite.cli.url' => ``'your.domain1.com',` ajout `'overwriteprotocol' => 'https',` Trusted domains: ``` array ( 0 => '192.168.x.x:8080', 1 => 'your.domain1.com', 2 => 'your.domain2.com' ), ```

Upload large files: https://www.youtube.com/watch?v=2-EbM9MyRBs

``` sudo nano /srv/path/NextCloud/config/.user.ini ``` ``` php_value upload_max_filesize 10G php_value post_max_size 10G php_value max_input_time 3600 php_value max_execution_time 3600 ``` ### Add these lines to your nginx config ``` fastcgi_connect_timeout 60; fastcgi_send_timeout 1800; fastcgi_read_timeout 1800; ``` #### **MANUALLY UPDATE**:

[https://www.vincent-gou.fr/post/nextcloud\_manual\_upgrade\_after\_docker\_update/](https://www.vincent-gou.fr/post/nextcloud_manual_upgrade_after_docker_update/)

### Connect Nextcloud docker container ``` [root@nas docker]# docker exec --user www-data -it nextcloud bash #or docker exec --user www-data -it nextcloud-app-1 bash ``` ### Control Nextcloud version ``` www-data@e73fd289077c:~/html$ php occ status Nextcloud or one of the apps require upgrade - only a limited number of commands are available You may use your browser or the occ upgrade command to do the upgrade - installed: true - version: 15.0.5.3 - versionstring: 15.0.5 - edition: www-data@e73fd289077c:~/html$ ``` ### Update Nextcloud ``` www-data@e73fd289077c:~/html$ php occ upgrade ``` ``` Nextcloud or one of the apps require upgrade - only a limited number of commands are available You may use your browser or the occ upgrade command to do the upgrade Set log level to debug Updating database schema Updated database [...] Starting code integrity check... Finished code integrity check Update successful Maintenance mode is kept active Reset log level ``` ### Deactivate maintenance mode ``` www-data@e73fd289077c:~/html$ php occ maintenance:mode --off Maintenance mode disabled www-data@e73fd289077c:~/html$ exit ``` ### Final setup Once update is finished, connect Nextcloud and check plugin app updates manually. Some apps may have been disabled during update process. You will have to activate them manually. Enjoy ! ### How to run occ command to add missing indices ```bash sudo docker exec --user www-data nextcloud-app-1 php occ db:add-missing-indices ``` ## [File Operations](https://docs.nextcloud.com/server/19/admin_manual/configuration_server/occ_command.html#file-operations-label) ``` php occ files:cleanup ``` tidies up the server’s file cache by deleting all file entries that have no matching entries in the storage table.