Eric Schirra
3c10fa2e43
- Update to 25.0.3 - Set page titel for each sidebar section through User management pages (server#35467) - Change header semantic in the user status dialog (server#35480) - Rename personal Groupware settings section to “Availability” (server#35492) - Remove old code from comment to not trigger automatic scanners more than needed (server#35497) - Add migration for encryption keys in wrong location (server#35499) - Fix SQL comparison with int array during external storage deletion (server#35516) - Fix the popovermenu (server#35517) - Bump @nextcloud/vue to 7.2.0 (server#35551) - Update ca-cert bundle (server#35573) - Fix type of PreviewController::$userId (server#35577) - Show success on share actions (server#35578) - Allow to set a custom timeout for ldap connections (server#35602) - Set page title for each sidebar section through User management pages (server#35629) - Fix contrast of global search headings (server#35639) - Add new border color variable and adjust primary color for increased contrast (server#35640) - Add success popup message for copying share links (server#35641) - Update psalm-baseline.xml (server#35663) - Update the unencrypted file size when closing streams (server#35668) - Update handlebars-loader to 1.7.3 (server#35673) - Add alt to the logo, adapt css for logo (server#35676) - Increase default global input field border contrast (server#35683) - Improve verbosity of search description (server#35688) - Fix default primary for user theming (server#35702) - Update sensitive config list of Talk (server#35706) - Show group name instead of group id as recommendation (server#35710) - Use correct filter for app icons in the right sidebar of app management (server#35711) - Improve email results for sharing (server#35712) - Ci: update minio image for s3 primary storage tests (server#35724) - Preview: fix HEIC orientation (server#35727) - Quota value as float for 32-bit systems (server#35734) - Fix vue-select styles (server#35742) - Read loginName from token (server#35747) - Change app menu focused items behavior that neighbor elements (text and border) have no overlapping (server#35771) - PHP8] check if params given to API are really an array (server#35797) - Fix missing cast of double controller parameters (server#35798) - Fix case sensitivity of email when saving settings (server#35803) - Restoring clearCachedConfig() (server#35812) - Use display name cache on getStorageInfo (server#35815) - Allow additional Sabre plugins in publicwebdav.php (server#35817) - Allow running encryption:fix-encrypted-version for all users (server#35827) - Fix parameter type for EntityCollection::setReadMarker in comments app (server#35835) - Fix: remove other shares from ui when deleted (server#35848) - Remove comment and guests option from Invitations UI (server#35859) - Increase preview_max_memory and make it easier to debug (server#35864) - Avatar generation – disable setimageformat (server#35895) - Fix video fullscreen on public page (server#35902) - Replace custom tooltips with native one for files sharing (server#35904) - Replace custom tooltips with native ones in files (server#35905) - Revert “avatar generation – disable setimageformat” (server#35914) - Update the user status dashboard widget and fix the icon color (server#35948) - Chore(CI): Improve rate limit situation when installing phpunit (server#35962) - Docs: trusted_proxies support IPv6 ranges (server#35963) - Also limit the password length on reset (server#35977) - Appsidebar should be compact when opened on small heights (server#35983) - Fix user status icon in avatar menu (server#35984) - Bump json5 from 1.0.1-1.0.2 and 2.2.0-2.2.3 (server#35988) - Remove myself from being codeowner of some modules (server#35992) - Bump @nextcloud/vue from 7.2.0 to 7.3.0 (server#35997) - Allow target=”_blank” in app navigation items (server#36007) - Fix default phone region validation (server#36010) - Update crl after revoke files_bpm.csr (server#36017) - Add restrictions when downloading to resolve with opengraph link provider (server#36022) - Fix scrolling while dragging in file list view (server#36028) - Fix cache key used to verify shared mountpoints (server#36049) - Link reference provider: Improve content-type check (server#36053) - Update ca-cert bundle (server#36059) - Fix theming migration repair step by passing correct type for argument (server#36081) - Allow keyup enter in user status (server#36132) - Revert “Allow keyup enter in user status” (server#36143) - Still include the share target in the cache key for validating share mount (server#36169) - Update nextcloud/ocp dependency (activity#1034) - Bump @nextcloud/vue from 7.0.0-beta.3 to 7.3.0 (activity#1043) - Fix background image size (firstrunwizard#790) - Update nextcloud/ocp dependency (firstrunwizard#799) - Various fixes (logreader#824) - Update nextcloud/ocp dependency (nextcloud_announcements#144) - Update nextcloud/ocp dependency (nextcloud_announcements#150) - Update nextcloud/ocp dependency (notifications#1399) - Bump deps to newer versions (notifications#1407) - Update nextcloud/ocp dependency (notifications#1413) - Bump postcss-loader from 7.0.1 to 7.0.2 (photos#1519) - Lazy load faces (photos#1523) - Remove broken icons.css references (photos#1533) - Bump postcss from 8.4.18 to 8.4.20 (photos#1545) - Bug fix] encode file name for file source (photos#1563) - Backport: #1569 to stable25 (photos#1574) - Bump @nextcloud/axios from 1.10.0 to 2.1.0 (recommendations#575) - Fix(deps): update tiptap (text#3486) - Fix(deps): update dependency @nextcloud/axios to ^2.2.0 (text#3487) - Chore(deps): update dependency vite-plugin-commonjs to ^0.6.0 (text#3491) - Prevent dangling debounced extractHeadings function (text#3522) - Only scroll images into view when they’re added (text#3533) - Don’t empty list of headings in onDestroy (text#3537) - Chore(deps): update dependency @cypress/webpack-preprocessor to ^5.15.6 (text#3539) - Chore(deps): update dependency @cypress/webpack-preprocessor to ^5.15.7 (text#3549) - Chore(deps): update dependency vite to ^3.2.5 (text#3553) - Chore(deps): update dependency vite-plugin-commonjs to ^0.6.1 (text#3554) - Fix(deps): update dependency path-normalize to ^6.0.9 (text#3555) - Fix(deps): update tiptap to ^2.0.0-beta.209 (text#3578) - Fix(deps): update dependency @nextcloud/axios to ^2.3.0 (text#3579) - Update nextcloud/ocp dependency (text#3582) - Chore(deps): update dependency @cypress/webpack-preprocessor to ^5.16.0 (text#3590) - Backport missing pieces for outline suport in Collectives (text#3593) - Block file access for secure view (text#3595) - Increase idle timeout to one day 40 minutes) (text#3597) - Fix(deps): update dependency @tiptap/prosemirror-tables to ^1.1.4 (text#3602) - Fix(deps): update dependency @nextcloud/vue to ^7.3.0 (text#3605) - Fix(deps): update dependency @nextcloud/router to ^2.0.1 (text#3612) - Chore(deps): update dependency @cypress/webpack-preprocessor to ^5.16.1 (text#3620) - Treat newlines as linebreaks when pasting as plaintext (text#3625) - Chore(deps): update dependency @nextcloud/eslint-config to ^8.1.5 (text#3629) - Fix: reconnect – reload main container (text#3635) - Npm audit fix (text#3638) - Fix(Images): Update image alt text on blur (text#3641) - Bump webdav from 4.11.0 to 4.11.2 (viewer#1484) - Bump camelcase from 7.0.0 to 7.0.1 (viewer#1493) - Bump @nextcloud/router from 2.0.0 to 2.0.1 (viewer#1508) - Update vue to 7.3 (viewer#1511) OBS-URL: https://build.opensuse.org/request/show/1059306 OBS-URL: https://build.opensuse.org/package/show/server:php:applications/nextcloud?expand=0&rev=191
329 lines
11 KiB
RPMSpec
329 lines
11 KiB
RPMSpec
#
|
|
# spec file for package nextcloud
|
|
#
|
|
# Copyright (c) 2023 SUSE LLC
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
#
|
|
%if 0%{?suse_version}
|
|
%define apache_myserverroot %{apache_serverroot}/htdocs
|
|
%define apache_confdir %{apache_sysconfdir}/conf.d
|
|
%define apache_docdir /usr/share/doc/packages
|
|
%else
|
|
%if 0%{?fedora_version} || 0%{?rhel_version} || 0%{?centos_version}
|
|
%define apache_serverroot /var/www/html
|
|
%define apache_confdir /etc/httpd/conf.d
|
|
%define apache_user apache
|
|
%define apache_group apache
|
|
%define __jar_repack 0
|
|
%else
|
|
%define apache_serverroot /var/www
|
|
%define apache_confdir /etc/httpd/conf.d
|
|
%define apache_user www
|
|
%define apache_group www
|
|
%endif
|
|
%endif
|
|
|
|
%define nc_user %{apache_user}
|
|
%define nc_dir %{apache_myserverroot}/%{name}
|
|
%define ocphp_bin /usr/bin
|
|
|
|
%if 0%{?rhel} == 600 || 0%{?rhel_version} == 600 || 0%{?centos_version} == 600
|
|
%define statedir /var/run
|
|
%else
|
|
%define statedir /run
|
|
%endif
|
|
|
|
Name: nextcloud
|
|
Version: 25.0.3
|
|
Release: 0
|
|
Summary: File hosting service
|
|
License: AGPL-3.0-only
|
|
Group: Productivity/Networking/Web/Utilities
|
|
URL: https://nextcloud.com
|
|
Source0: https://download.nextcloud.com/server/releases/%{name}-%{version}.tar.bz2
|
|
Source1: apache_secure_data
|
|
Source2: README
|
|
Source3: README.SELinux
|
|
Source4: README.SUSE
|
|
Source5: robots.txt
|
|
Source10: %{name}-cron
|
|
Source11: %{name}-cron.service
|
|
Source12: %{name}-cron.timer
|
|
Source99: %{name}-rpmlintrc
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
BuildArch: noarch
|
|
BuildRequires: apache-rpm-macros
|
|
BuildRequires: cron
|
|
BuildRequires: fdupes
|
|
BuildRequires: unzip
|
|
#
|
|
Requires: cron
|
|
Requires: curl
|
|
Requires: libxml2-2
|
|
Requires: mariadb >= 10.2
|
|
Requires: php-bz2
|
|
Requires: php-dom
|
|
Requires: php-gd
|
|
Requires: php-intl
|
|
Requires: php-json
|
|
Requires: php-mbstring
|
|
Requires: php-mysql
|
|
Requires: php-posix
|
|
Requires: php-zip
|
|
#
|
|
%if 0%{?fedora_version} || 0%{?rhel} || 0%{?rhel_version} || 0%{?centos_version}
|
|
Requires: php < 8.2.0
|
|
Requires: php >= 7.4.0
|
|
Requires: php-process
|
|
Requires: php-xml
|
|
Recommends: sqlite
|
|
%endif
|
|
#
|
|
%if 0%{?suse_version}
|
|
Requires: php-ctype
|
|
Requires: php-curl
|
|
# SUSE does not include the fileinfo module in php-common.
|
|
Requires: php-fileinfo
|
|
Requires: php-iconv
|
|
Requires: php-openssl
|
|
Requires: php-pear
|
|
Requires: php-xmlreader
|
|
Requires: php-xmlwriter
|
|
Requires: php-zip
|
|
Requires: php-zlib
|
|
Recommends: sqlite3
|
|
%{?systemd_requires}
|
|
%endif
|
|
# Database connectors:
|
|
Recommends: php-sqlite
|
|
#Recommends: php-pgsql
|
|
# Require for specific apps:
|
|
Requires: php-ftp
|
|
Requires: php-ldap
|
|
#Requires: php-imap
|
|
#Requires: php-smbclient
|
|
# Recommend for specific apps:
|
|
Recommends: php-exif
|
|
Recommends: php-gmp
|
|
# For enhanced server performance:
|
|
Recommends: php-APCu
|
|
Recommends: php-bcmath
|
|
# For preview generation:
|
|
Recommends: php-imagick
|
|
Recommends: php-ffmpeg
|
|
#Recommends: libreoffice
|
|
# For command line processing:
|
|
Recommends: php-pcntl
|
|
|
|
%description
|
|
Nextcloud is a suite of client-server software for creating file
|
|
hosting services and using them.
|
|
|
|
%package apache
|
|
Summary: Apache configuration for %{name}
|
|
Group: Productivity/Networking/Web/Utilities
|
|
BuildRequires: apache2 >= 2.4
|
|
Requires: %{name} = %{version}
|
|
Requires: apache2
|
|
Requires: mod_php_any < 8.2.0
|
|
Requires: mod_php_any >= 7.4.0
|
|
Supplements: packageand(apache2:%name)
|
|
|
|
%description apache
|
|
This subpackage contains the Apache configuration files
|
|
|
|
%prep
|
|
%setup -q -n %{name}
|
|
cp %{SOURCE2} .
|
|
cp %{SOURCE3} .
|
|
cp %{SOURCE4} .
|
|
cp %{SOURCE5} .
|
|
### Don't remove git files!!
|
|
### git files should not be removed, otherwise nextcloud rise up integrity check failure in some situations.
|
|
###
|
|
## delete unneeded gitfiles
|
|
#rm -r `find . -name ".gitignore" -or -name ".gitkeep" -or -name ".github"`
|
|
## remove entries in signature.json to prevent integrity check failure
|
|
#find . -iname signature.json \
|
|
# -exec sed -i "/\/.gitignore\": ./d" "{}" \; \
|
|
# -exec sed -i "/\/.gitkeep\": ./d" "{}" \; \
|
|
# -exec sed -i "/\/.github\": ./d" "{}" \;
|
|
#rm -f 3rdparty/symfony/debug/Resources/ext/*.{c,h}
|
|
|
|
%build
|
|
|
|
%install
|
|
# no server side java code contained, alarm is false
|
|
idir=$RPM_BUILD_ROOT/%{apache_myserverroot}/%{name}
|
|
mkdir -p $idir
|
|
mkdir -p $idir/data
|
|
mkdir -p $idir/search
|
|
cp -aRf * $idir
|
|
cp -aRf .htaccess $idir
|
|
cp -aRf .user.ini $idir
|
|
# $idir/l10n to disappear in future
|
|
#rm -f $idir/l10n/l10n.pl
|
|
|
|
if [ ! -f $idir/robots.txt ]; then
|
|
install -p -D -m 644 %{SOURCE5} $idir/robots.txt
|
|
fi
|
|
|
|
# create the AllowOverride directive
|
|
install -p -D -m 644 %{SOURCE1} $RPM_BUILD_ROOT/%{apache_confdir}/nextcloud.conf
|
|
ocpath="%{apache_myserverroot}/%{name}"
|
|
sed -i -e"s|@DATAPATH@|${ocpath}|g" $RPM_BUILD_ROOT/%{apache_confdir}/nextcloud.conf
|
|
|
|
# not needed for distro packages
|
|
rm -f ${idir}/indie.json
|
|
|
|
%if 0%{?suse_version}
|
|
# link duplicate doc files
|
|
%fdupes -s $RPM_BUILD_ROOT/%{apache_myserverroot}/%{name}
|
|
%endif
|
|
|
|
# CronJob
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/cron.d
|
|
install -D -m 0644 %{SOURCE10} %{buildroot}%{_sysconfdir}/cron.d/%{name}
|
|
install -D -m 0644 %{SOURCE11} %{buildroot}%{_unitdir}/%{name}-cron.service
|
|
install -D -m 0644 %{SOURCE12} %{buildroot}%{_unitdir}/%{name}-cron.timer
|
|
sed -i -e"s|@APACHE_USER@|%{apache_user}|g" %{buildroot}%{_sysconfdir}/cron.d/%{name}
|
|
sed -i -e"s|@APACHE_MYSERVERROOT@|%{apache_myserverroot}|g" %{buildroot}%{_sysconfdir}/cron.d/%{name}
|
|
sed -i -e"s|@APACHE_USER@|%{apache_user}|g" %{buildroot}%{_unitdir}/%{name}-cron.service
|
|
sed -i -e"s|@APACHE_MYSERVERROOT@|%{apache_myserverroot}|g" %{buildroot}%{_unitdir}/%{name}-cron.service
|
|
mkdir -p %{buildroot}%{_sbindir}
|
|
ln -sf %{_sbindir}/service %{buildroot}%{_sbindir}/rc%{name}-cron
|
|
|
|
%pre
|
|
%service_add_pre %{name}-cron.timer %{name}-cron.service
|
|
|
|
# avoid fatal php errors, while we are changing files
|
|
# https://github.com/nextcloud
|
|
#
|
|
# We don't do this for new installs. Only for updates.
|
|
# If the first argument to pre is 1, the RPM operation is an initial installation. If the argument is 2,
|
|
# the operation is an upgrade from an existing version to a new one.
|
|
if [ $1 -gt 1 -a ! -s %{statedir}/apache_stopped_during_nextcloud_install ]; then
|
|
echo "o %{name} pre-install: Checking for running Apache"
|
|
# FIXME: this above should make it idempotent -- a requirement with openSUSE.
|
|
# it does not work.
|
|
%if 0%{?suse_version} && 0
|
|
service apache2 status | grep running > %{statedir}/apache_stopped_during_nextcloud_install
|
|
service apache2 stop
|
|
%endif
|
|
%if 0%{?fedora_version} || 0%{?rhel_version} || 0%{?centos_version}
|
|
service httpd status | grep running > %{statedir}/apache_stopped_during_nextcloud_install
|
|
service httpd stop
|
|
%endif
|
|
fi
|
|
if [ -s %{statedir}/apache_stopped_during_nextcloud_install ]; then
|
|
echo "o %{name} pre-install: Stopping Apache"
|
|
fi
|
|
|
|
if [ $1 -eq 1 ]; then
|
|
echo "o %{name} pre-install: First install starting"
|
|
else
|
|
echo "o %{name} pre-install: Upgrade starting ..."
|
|
fi
|
|
# https://github.com/nextcloud
|
|
if [ -x %{ocphp_bin}/php -a -f %{nc_dir}/occ ]; then
|
|
echo "o %{name} pre-install: occ maintenance:mode --on"
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ maintenance:mode --on" || true
|
|
echo yes > %{statedir}/occ_maintenance_mode_during_nextcloud_install
|
|
fi
|
|
|
|
%post
|
|
%service_add_post %{name}-cron.timer %{name}-cron.service
|
|
|
|
if [ $1 -eq 1 ]; then
|
|
%if 0%{?suse_version}
|
|
%if 0%{?sle_version} >= 150400 || 0%{?suse_version} > 1500
|
|
a2enmod php8
|
|
%else
|
|
a2enmod php7
|
|
%endif
|
|
%endif
|
|
fi
|
|
|
|
if [ -s %{statedir}/apache_stopped_during_nextcloud_install ]; then
|
|
echo "o %{name} post-install: Restarting Apache"
|
|
## If we stopped apache in pre section, we now should restart. -- but *ONLY* then!
|
|
## Maybe delegate that task to occ upgrade? They also need to handle this, somehow.
|
|
%if 0%{?suse_version}
|
|
service apache2 start
|
|
%endif
|
|
%if 0%{?fedora_version} || 0%{?rhel_version} || 0%{?centos_version}
|
|
service httpd start
|
|
%endif
|
|
fi
|
|
|
|
if [ -s %{statedir}/occ_maintenance_mode_during_nextcloud_install ]; then
|
|
echo "o %{name} post-install: occ maintenance:repair (fix possible errors)"
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ maintenance:repair" || true
|
|
echo "o %{name} post-install: occ db:add-missing-* (add missing db things)"
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ maintenance:mimetype:update-db" || true
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ db:add-missing-columns" || true
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ db:add-missing-indices" || true
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ db:add-missing-primary-keys" || true
|
|
echo "o %{name} post-install: occ update apps"
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ app:update --all" || true
|
|
echo "o %{name} post-install: occ upgrade"
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ upgrade" || true
|
|
echo "o %{name} post-install: occ maintenance:mode --off"
|
|
su %{nc_user} -s /bin/sh -c "cd %{nc_dir}; PATH=%{ocphp_bin}:$PATH php ./occ maintenance:mode --off" || true
|
|
fi
|
|
|
|
rm -f %{statedir}/apache_stopped_during_nextcloud_install
|
|
rm -f %{statedir}/occ_maintenance_mode_during_nextcloud_install
|
|
|
|
if [ $1 -eq 1 ]; then
|
|
echo "o %{name} post-install: First install complete"
|
|
else
|
|
echo "o %{name} post-install: Upgrade complete"
|
|
fi
|
|
|
|
%preun
|
|
%service_del_preun %{name}-cron.timer %{name}-cron.service
|
|
|
|
%postun
|
|
%service_del_postun %{name}-cron.timer %{name}-cron.service
|
|
|
|
%files
|
|
%defattr(644,root,root,755)
|
|
%exclude %{apache_myserverroot}/%{name}/README
|
|
%exclude %{apache_myserverroot}/%{name}/README.SUSE
|
|
%exclude %{apache_myserverroot}/%{name}/README.SELinux
|
|
%doc README README.SUSE README.SELinux
|
|
%config(noreplace) %{_sysconfdir}/cron.d/%{name}
|
|
%{_sbindir}/rc%{name}-cron
|
|
%{_unitdir}/%{name}-cron.service
|
|
%{_unitdir}/%{name}-cron.timer
|
|
%{apache_myserverroot}/%{name}
|
|
%attr(-,%{apache_user},%{apache_group}) %{apache_myserverroot}/%{name}/occ
|
|
%config(noreplace) %{apache_myserverroot}/%{name}/.user.ini
|
|
%defattr(664,%{apache_user},%{apache_group},775)
|
|
%{apache_myserverroot}/%{name}/apps
|
|
%{apache_myserverroot}/%{name}/core/js/mimetypelist.js
|
|
%dir %{apache_myserverroot}/%{name}/core/img/filetypes
|
|
%{apache_myserverroot}/%{name}/core/img/filetypes/*
|
|
%defattr(660,%{apache_user},%{apache_group},770)
|
|
%{apache_myserverroot}/%{name}/config
|
|
%{apache_myserverroot}/%{name}/data
|
|
|
|
%files apache
|
|
%config(noreplace) %{apache_confdir}/nextcloud.conf
|
|
|
|
%changelog
|