Re: Nextclount 29.0.2 update - /etc/webapps/nextcloud/.htaccess.pacnew missing Arch webapp config?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Hi David,

On 2024-06-06 21:18:14 (-0500), David C. Rankin wrote:
>   The upper part is the same, but the lines from the bottom are removed:
> 
> --- .htaccess.20240523  2024-06-06 20:55:04.132401657 -0500
> +++ .htaccess.20240606  2024-06-06 08:57:25.000000000 -0500
> @@ -108,29 +108,3 @@
> 
>  AddDefaultCharset utf-8
>  Options -Indexes
> -#### DO NOT CHANGE ANYTHING ABOVE THIS LINE ####
> -
> -ErrorDocument 403 /nextcloud/index.php/error/403
> -ErrorDocument 404 /nextcloud/index.php/error/404
> -<IfModule mod_rewrite.c>
> -  Options -MultiViews
> -  RewriteRule ^core/js/oc.js$ index.php [PT,E=PATH_INFO:$1]
> -  RewriteRule ^core/preview.png$ index.php [PT,E=PATH_INFO:$1]
> -  RewriteCond %{REQUEST_FILENAME} !\.(css|js|mjs|svg|gif|png|html|ttf|woff2?|ico|jpg|jpeg|map|webm|mp4|mp3|ogg|wav|flac|wasm|tflite)$
> -  RewriteCond %{REQUEST_FILENAME} !/core/ajax/update\.php
> -  RewriteCond %{REQUEST_FILENAME} !/core/img/(favicon\.ico|manifest\.json)$
> -  RewriteCond %{REQUEST_FILENAME} !/(cron|public|remote|status)\.php
> -  RewriteCond %{REQUEST_FILENAME} !/ocs/v(1|2)\.php
> -  RewriteCond %{REQUEST_FILENAME} !/robots\.txt
> -  RewriteCond %{REQUEST_FILENAME} !/(ocs-provider|updater)/
> -  RewriteCond %{REQUEST_URI} !^/\.well-known/(acme-challenge|pki-validation)/.*
> -  RewriteCond %{REQUEST_FILENAME} !/richdocumentscode(_arm64)?/proxy.php$
> -  RewriteRule . index.php [PT,E=PATH_INFO:$1]
> -  RewriteBase /nextcloud
> -  <IfModule mod_env.c>
> -    SetEnv front_controller_active true
> -    <IfModule mod_dir.c>
> -      DirectorySlash off
> -    </IfModule>
> -  </IfModule>
> -</IfModule>

IIRC, the above changes are something that nextcloud itself adds to the file
during initial configuration. If you want to continue running nextcloud as
before you will want to keep those lines.
The `DO NOT CHANGE ANYTHING ABOVE THIS LINE` comment implies that anything above
that line is vendor provided (coming from nextcloud upstream) though and should
always be kept in sync with changes provided by updates.

As an aside:
This is why the /etc/webapps/nextcloud/.htaccess file is owned by the nextcloud
user and /usr/share/webapps/nextcloud/.htaccess is a symlink to it.

Similar to other files that are tracked in the context of the backup array [1]
of a package you are expected to adapt the file accordingly (this has been the
case for many nextcloud versions already) and not necessarily apply all changes
provided by the updated file (this is also the case for other packages FWIW, as
you often want to keep your specific modifications).

I hope this clears things up.

Best,
David

[1] https://wiki.archlinux.org/title/PKGBUILD#backup

-- 
https://sleepmap.de

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux