[arch-commits] Commit in nextcloud/trunk (PKGBUILD nextcloud-21.0.0-config.patch)

David Runge dvzrv at archlinux.org
Sat Feb 20 12:55:58 UTC 2021


    Date: Saturday, February 20, 2021 @ 12:55:57
  Author: dvzrv
Revision: 866806

upgpkg: nextcloud 21.0.0-4: Rebuild to apply config patch.

Apply patch to config.sample.php to set directories for state and log files to the FHS
compliant directories provided by the package.
Add symlink for writable apps location in /var/lib/nextcloud/apps.

Added:
  nextcloud/trunk/nextcloud-21.0.0-config.patch
Modified:
  nextcloud/trunk/PKGBUILD

-------------------------------+
 PKGBUILD                      |   10 +++++++++-
 nextcloud-21.0.0-config.patch |   36 ++++++++++++++++++++++++++++++++++++
 2 files changed, 45 insertions(+), 1 deletion(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-02-20 12:52:19 UTC (rev 866805)
+++ PKGBUILD	2021-02-20 12:55:57 UTC (rev 866806)
@@ -3,7 +3,7 @@
 
 pkgname=nextcloud
 pkgver=21.0.0
-pkgrel=3
+pkgrel=4
 pkgdesc="A cloud server to store your files centrally on a hardware controlled by you"
 arch=('any')
 url="https://nextcloud.com"
@@ -40,6 +40,7 @@
 install="${pkgname}.install"
 source=(
   "https://download.nextcloud.com/server/releases/nextcloud-${pkgver}.tar.bz2"{,.asc}
+  "${pkgname}-21.0.0-config.patch"
   'apache.example.conf'
   "${pkgname}.hook"
   "${pkgname}.occ.sh"
@@ -49,6 +50,7 @@
 )
 sha512sums=('a1ae3400f0fb5997e54b0cee821c50d13e4ba0e27c9d11731c8b5233cba564666121a58aed848ccd2593a9783e27db1ed98ff559588a76a1acaeaf083ef4404a'
             'SKIP'
+            '7e5f72591e7a8d2dde9d1cca2a3cff2bd5e48a8e938540dd94dbdc2eb35056a5d4f60f0c0bdbfdd080474e078b4f36b61650d9ed38927e50b29a29613506fd39'
             '6f9f284d78d414a3bb7c159a812b105e31e8cd2393afee44465701e6f18169709f6d492d790e403e1e66f308c51b6b6496d29ddce29e4fac2c73a3c84a10c7fe'
             '7b18b73ee369607b8ee3d00d2a054262a7b8f3033fc4873eb333c9b9333d7338870c035910ae123b564a65d7d245730178137311048f0713d5bc524de3654923'
             'cd86397e08459c9f06cfd44ff27a35879157166f5e8aab95d51bc7c4bb11f93e7c414a08ec1cbe9e81f1b4edfbf5eb5eaba7c6904da80a2c92c765bcb546aa66'
@@ -57,6 +59,7 @@
             'a3ebcabcdb8c2d2653f44a248abd213bc4dbb317766b82c8f3e93b31e72ace350d7e8037bd4e22a632ab33f739e1941467b0e9d2cf7d0a7433227b4169030051')
 b2sums=('7c583c150f6b315830191329310993582439e7aef57f306b93681d654b8fa7d4d5dafee082befd493aafd2bf6efd940d52ca0ca05b8e42b79a1599ff3e809550'
         'SKIP'
+        '2b84b21e40c9493869670e851b545692d3a53705a0ee3564dd002be135c553b73ad124f27e91f0c2bda1ce110e8bd5b62c0678f5fead4598826cb41dbc2dc3d3'
         'a7e1aa1d8cb2b0ff7832bb7d6d857987733253317c0f3727e744502aeaa3b2008351b47ecc24e348fe7b252cefaffe2418797523ee288dfd55e128917e8fbe2c'
         '772a9571fe7d88dbcbeb46351a188354e237dfe8e020131f2752b3a36cff0ff177423b4cfd6a1a5f28946f86a8581f3e24ee06ebda7260c5f862ca4071908e43'
         '6a90659bf0ab7163fe0cf591abed9b58b9ff09c548698e7f8844ecc710917cf05561bad754f6d7543593d13b41e9ec630042b4fc3fbad43e1011b0e45868e4ed'
@@ -67,6 +70,9 @@
 
 prepare() {
   mv -v "${pkgname}" "${pkgname}-${pkgver}"
+  cd "${pkgname}-${pkgver}"
+  # patch config.sample.php to use FHS compliant paths for state and logs
+  patch -Np1 -i ../"${pkgname}-21.0.0-config.patch"
 }
 
 package() {
@@ -137,4 +143,6 @@
   install -vDm 755 occ -t "${pkgdir}/usr/share/webapps/${pkgname}"
   # apache example conf
   install -vDm 644 ../apache.example.conf -t "${pkgdir}/usr/share/doc/${pkgname}/"
+  # add symlink for default writable apps directory
+  ln -sv "/var/lib/${pkgname}/apps" "${pkgdir}/usr/share/webapps/${pkgname}/wapps"
 }

Added: nextcloud-21.0.0-config.patch
===================================================================
--- nextcloud-21.0.0-config.patch	                        (rev 0)
+++ nextcloud-21.0.0-config.patch	2021-02-20 12:55:57 UTC (rev 866806)
@@ -0,0 +1,36 @@
+diff -ruN a/config/config.sample.php b/config/config.sample.php
+--- a/config/config.sample.php	2021-02-19 09:49:36.000000000 +0100
++++ b/config/config.sample.php	2021-02-20 13:29:19.194514157 +0100
+@@ -83,7 +83,7 @@
+  *
+  * Default to ``data/`` in the Nextcloud directory.
+  */
+-'datadirectory' => '/var/www/nextcloud/data',
++'datadirectory' => '/var/lib/nextcloud/data',
+ 
+ /**
+  * The current version number of your Nextcloud installation. This is set up
+@@ -831,7 +831,7 @@
+  *
+  * Defaults to ``[datadirectory]/nextcloud.log``
+  */
+-'logfile' => '/var/log/nextcloud.log',
++'logfile' => '/var/log/nextcloud/nextcloud.log',
+ 
+ /**
+  * Log file mode for the Nextcloud loggin type in octal notation.
+@@ -968,8 +968,13 @@
+  */
+ 'apps_paths' => [
+ 	[
+-		'path'=> '/var/www/nextcloud/apps',
++		'path'=> '/usr/share/webapps/nextcloud/apps',
+ 		'url' => '/apps',
++		'writable' => false,
++	],
++	[
++		'path'=> '/var/lib/nextcloud/apps',
++		'url' => '/wapps',
+ 		'writable' => true,
+ 	],
+ ],


More information about the arch-commits mailing list