Modify variable styling

This commit is contained in:
RealStickman 2023-02-19 15:34:22 +01:00
parent 9913447ba2
commit cf40642adc

View File

@ -29,7 +29,7 @@ For UTF8 support use this instead:
```sql
CREATE DATABASE nextcloud CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;
GRANT ALL ON nextcloud.* TO 'nextcloud'@'localhost' IDENTIFIED BY '<password>';
GRANT ALL ON nextcloud.* TO 'nextcloud'@'localhost' IDENTIFIED BY '{PASSWORD}';
FLUSH PRIVILEGES;
```
@ -38,8 +38,8 @@ Exit the MariaDB prompt
Download Nextcloud into `/var/www`
```sh
wget https://download.nextcloud.com/server/releases/nextcloud-(version).tar.bz2
tar -xf nextcloud-(version).tar.bz2
wget https://download.nextcloud.com/server/releases/nextcloud-{VERSION}.tar.bz2
tar -xf nextcloud-{VERSION}.tar.bz2
```
Change owner to the apache user
@ -57,7 +57,7 @@ vi /etc/apache2/sites-available/nextcloud.conf
Configuration file
```apacheconf
<VirtualHost *:80> #specify listen ip addresses: (address):(port) for ipv4, [(address)]:(port) vor ipv6, *:80 for all
<VirtualHost *:80> #specify listen ip addresses: {ADDRESS}:{PORT} for ipv4, [{ADDRESS}]:{PORT} vor ipv6, *:80 for all
ServerAdmin webmaster@localhost
DocumentRoot /var/www/nextcloud
Alias /nextcloud "/var/www/nextcloud/"
@ -130,7 +130,7 @@ This disables the warning of untrusted proxy in the webinterface.
```
'trusted_proxies' =>
array (
0 => '<proxy ip>',
0 => '{PROXY IP}',
),
```
@ -141,8 +141,8 @@ Array of trusted domains.
```
'trusted_domains' =>
array (
0 => '<domain 1>',
1 => '<domain 2>',
0 => '{DOMAIN 1}',
1 => '{DOMAIN 2}',
),
```
@ -168,8 +168,10 @@ sudo -u www-data php /var/www/nextcloud/updater/updater.phar
Dump database to file
_NOTE: The password needs to be inserted directly after `-p` without any space_
```sh
mysqldump --single-transaction -h [server] -u [username] -p[password] [db_name] > nextcloud-sqlbkp_`date +"%Y%m%d"`.bak
mysqldump --single-transaction -h {SERVER} -u {USERNAME} -p{PASSWORD} {DB NAME} > nextcloud-sqlbkp_`date +"%Y%m%d"`.bak
```
> [Official documentation](https://docs.nextcloud.com/server/latest/admin_manual/maintenance/backup.html)
@ -197,12 +199,12 @@ sudo -u www-data php /var/www/nextcloud/occ maintenance:mode --off
### Restore Database
```sh
mariadb -h $server -u $username -p$password -e "DROP DATABASE nextcloud"
mariadb -h $server -u $username -p$password -e "CREATE DATABASE nextcloud CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci"
mariadb -h {SERVER} -u {USERNAME} -p{PASSWORD} -e "DROP DATABASE nextcloud"
mariadb -h {SERVER} -u {USERNAME} -p{PASSWORD} -e "CREATE DATABASE nextcloud CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci"
```
```sh
mariadb -h $server -u $username -p$password $db_name < nextcloud-sqlbkp.bak
mariadb -h {SERVER} -u {USERNAME} -p{PASSWORD} {DB NAME} < nextcloud-sqlbkp.bak
```
> [Nextcloud documentation](https://docs.nextcloud.com/server/latest/admin_manual/maintenance/restore.html)