/[packages]/backports/8/nextcloud/current/SPECS/nextcloud.spec
ViewVC logotype

Annotation of /backports/8/nextcloud/current/SPECS/nextcloud.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1562464 - (hide annotations) (download)
Mon Mar 30 19:53:20 2020 UTC (4 years ago) by joequant
Original Path: cauldron/nextcloud/current/SPECS/nextcloud.spec
File size: 7210 byte(s)
remove major release

1 joequant 1562464 %define major_version 18
2     %define version %{major_version}.0.3
3     %define rel 5
4 blino 1218538 %define prerel %{nil}
5 joequant 1562464 %define name_root nextcloud
6 neoclust 1036847
7     %if "%{prerel}" != "%{nil}"
8     %define lc_prerel %(echo %{prerel} | tr "A-Z" "a-z")
9     %define release %mkrel 1.%{lc_prerel}.%{rel}
10     %else
11     %define release %mkrel %{rel}
12     %endif
13    
14 guillomovitch 1153655 # exclude PHP dependencies as long as their usage is not proven
15     %define __requires_exclude_from ^%{_datadir}/.*$
16 neoclust 1036847 %define __jar_repack %{nil}
17    
18     Summary: Open personal cloud
19 joequant 1562464 Name: %{name_root}
20 neoclust 1036847 Version: %{version}
21     Release: %{release}
22     License: AGPLv3
23 guillomovitch 1153655 Group: Networking/WWW
24 neoclust 1038684 Url: http://nextcloud.com
25 joequant 1562464 Source0: https://download.nextcloud.com/server/releases/%{name_root}-%{version}%{?prerel}.tar.bz2
26     Source1: %{name_root}-httpd.conf
27     Source2: %{name_root}-httpd.inc
28     Source4: %{name_root}-mysql.txt
29     Source5: %{name_root}-postgresql.txt
30     Source7: %{name_root}-config.php
31     Source8: %{name_root}-fpm.conf
32 guillomovitch 1153655 # Disable the integrity checking whilst a better way to deal with it is found
33 joequant 1562464 Patch5: %{name_root}-14.4.0-default_integrity_check_disabled.patch
34 guillomovitch 1153655 # Direct the admin to the correct cli command for upgrades
35 joequant 1562464 Patch9: %{name_root}-12.0.2-correct-cli-upgrade.patch
36     Requires: php-webinterface >= 3:7.2.0
37 zezinho 1340852 Requires: php-curl >= 3:7.2.0
38     Requires: php-dom >= 3:7.2.0
39     Requires: php-exif >= 3:7.2.0
40     Requires: php-fileinfo >= 3:7.2.0
41     Requires: php-gd >= 3:7.2.0
42     Requires: php-iconv >= 3:7.2.0
43 zezinho 1430479 Requires: php-imagick
44 zezinho 1450614 Recommends: php-intl >= 3:7.2.0
45 zezinho 1340852 Requires: php-json >= 3:7.2.0
46     Requires: php-ldap >= 3:7.2.0
47     Requires: php-mbstring >= 3:7.2.0
48     Requires: php-openssl >= 3:7.2.0
49     Requires: php-pcre >= 3:7.2.0
50     Recommends: php-pcntl >= 3:7.2.0
51     Requires: php-pdo >= 3:7.2.0
52     Requires: php-session >= 3:7.2.0
53     Requires: php-simplexml >= 3:7.2.0
54     Requires: php-xmlwriter >= 3:7.2.0
55     Requires: php-zip >= 3:7.2.0
56     Requires: php-filter >= 3:7.2.0
57 guillomovitch 1153655 Requires: %{name}-database = %{version}-%{release}
58 joequant 1562464 Requires: openssl >= 1.0.2f
59     Obsoletes: nextcloud <= 17.0.0.0
60     Obsoletes: nextcloud17 <= 18.0.0.0
61     Obsoletes: nextcloud18 < %{version}
62 neoclust 1036847 BuildArch: noarch
63    
64     %description
65     A personal cloud server which runs on you personal server
66     and enables accessing your data from everywhere and sharing
67     with other people.
68    
69 guillomovitch 1153655 %package mysql
70     Summary: MySQL database support for NextCloud
71     Provides: %{name}-database = %{version}-%{release}
72     Requires: %{name} = %{version}-%{release}
73     # From getSupportedDatabases, mysql => pdo, mysql
74 zezinho 1340852 Requires: php-pdo_mysql >= 3:7.2.0
75 guillomovitch 1153655
76     %description mysql
77     This package ensures the necessary dependencies are in place for NextCloud to
78     work with MySQL / MariaDB databases. It does not require a MySQL / MariaDB
79     server to be installed, as you may well wish to use a remote database
80     server.
81     If you want the database to be on the same system as NextCloud itself, you must
82     also install and enable a MySQL / MariaDB server package. See README.mysql for
83     more details.
84    
85     %package postgresql
86     Summary: PostgreSQL database support for NextCloud
87     Provides: %{name}-database = %{version}-%{release}
88     Requires: %{name} = %{version}-%{release}
89     # From getSupportedDatabases, pgsql => function, pg_connect
90 zezinho 1340852 Requires: php-pdo_pgsql >= 3:7.2.0
91 guillomovitch 1153655
92     %description postgresql
93     This package ensures the necessary dependencies are in place for NextCloud to
94     work with a PostgreSQL database. It does not require the PostgreSQL server
95     package to be installed, as you may well wish to use a remote database
96     server.
97     If you want the database to be on the same system as NextCloud itself, you must
98     also install and enable the PostgreSQL server package. See README.postgresql
99     for more details.
100    
101     %package sqlite
102     Summary: SQLite 3 database support for NextCloud
103     Provides: %{name}-database = %{version}-%{release}
104     Requires: %{name} = %{version}-%{release}
105     # From getSupportedDatabases, pgsql => class, SQLite3
106 zezinho 1340852 Requires: php-pdo_sqlite >= 3:7.2.0
107     Requires: php-pcre >= 3:7.2.0
108 guillomovitch 1153655
109     %description sqlite
110     This package ensures the necessary dependencies are in place for NextCloud to
111     work with an SQLite 3 database stored on the local system.
112    
113 neoclust 1036847 %prep
114 joequant 1562464 %setup -q -n nextcloud
115 guillomovitch 1153655 %autopatch -p 1
116     cp %{SOURCE4} README.mysql
117     cp %{SOURCE5} README.postgresql
118 neoclust 1036847
119 guillomovitch 1153655 # drop upstream update notification app
120     rm -rf apps/updatenotification
121     # also remove the actual updater
122     rm -rf updater
123    
124 neoclust 1036847 %install
125 joequant 1562464 install -d -m 755 %{buildroot}%{_datadir}/%{name_root}
126 guillomovitch 1153655 # create nextcloud datadir
127 joequant 1562464 install -d -m 755 %{buildroot}%{_localstatedir}/lib/%{name_root}/data
128 guillomovitch 1153655 # create writable app dir for appstore
129 joequant 1562464 install -d -m 755 %{buildroot}%{_localstatedir}/lib/%{name_root}/apps
130 guillomovitch 1153655 # create nextcloud sysconfdir
131 joequant 1562464 install -d -m 755 %{buildroot}%{_sysconfdir}/%{name_root}
132 neoclust 1036847
133 guillomovitch 1153655 # install content
134     for d in $(find . -mindepth 1 -maxdepth 1 -type d | grep -v config); do
135 joequant 1562464 cp -a "$d" %{buildroot}%{_datadir}/%{name_root}
136 guillomovitch 1153655 done
137 neoclust 1036847
138 neoclust 1190552 for f in {*.php,*.html,occ,robots.txt}; do
139 joequant 1562464 install -p -m 644 "$f" %{buildroot}%{_datadir}/%{name_root}
140 guillomovitch 1153655 done
141 neoclust 1036847
142 guillomovitch 1153655 # symlink config dir
143 joequant 1562464 ln -sf %{_sysconfdir}/%{name_root} %{buildroot}%{_datadir}/%{name_root}/config
144 neoclust 1036847
145 guillomovitch 1153655 # nextcloud looks for ca-bundle.crt in config dir
146 joequant 1562464 ln -sf %{_sysconfdir}/pki/tls/certs/ca-bundle.crt %{buildroot}%{_sysconfdir}/%{name_root}/ca-bundle.crt
147 neoclust 1036847
148 guillomovitch 1153655 # set default config
149 joequant 1562464 install -p -m 644 %{SOURCE7} %{buildroot}%{_sysconfdir}/%{name_root}/config.php
150 neoclust 1036847
151 joequant 1562464 install -D -m 644 %{SOURCE1} %{buildroot}%{webappconfdir}/%{name_root}.conf
152     install -D -m 644 %{SOURCE2} %{buildroot}%{webappconfdir}/%{name_root}.inc
153     install -D -m 644 %{SOURCE8} %{buildroot}%{_sysconfdir}/php-fpm.d/%{name_root}.conf
154 neoclust 1036847
155 joequant 1562464 cat > %{buildroot}%{_datadir}/%{name_root}/.htaccess <<EOF
156 guillomovitch 1153655 # Version: %{version}
157     EOF
158 neoclust 1036847
159 guillomovitch 1153655 install -d -m 755 %{buildroot}%{_sysconfdir}/cron.d
160 joequant 1562464 cat > %{buildroot}%{_sysconfdir}/cron.d/%{name_root} <<EOF
161 guillomovitch 1153655 # Run cron from to execute task even when no user connected
162     */15 * * * * apache /usr/bin/php -f /usr/share/nextcloud/cron.php
163     EOF
164 neoclust 1036847
165 zezinho 1184605
166 guillomovitch 1153655 %pre
167     # on update from previous release, move data directory from
168     # %{_localstatedir}/lib/%{name} to %{_localstatedir}/lib/%{name}/data
169     if [ $1 -gt 1 ] ; then
170 joequant 1562464 if [ -d %{_localstatedir}/lib/%{name_root}/ -a ! -d %{_localstatedir}/lib/%{name_root}/data ]; then
171     mv %{_localstatedir}/lib/%{name_root} %{_localstatedir}/lib/%{name_root}.tmp
172     mkdir %{_localstatedir}/lib/%{name_root}
173     mv %{_localstatedir}/lib/%{name_root}.tmp %{_localstatedir}/lib/%{name_root}/data
174 guillomovitch 1153655 fi
175     fi
176 neoclust 1036847
177 zezinho 1184602
178 guillomovitch 1153655 %files
179 zezinho 1340852 %doc AUTHORS config/config.sample.php
180 neoclust 1036847
181 joequant 1562464 %dir %attr(-,apache,apache) %{_sysconfdir}/%{name_root}
182     %config(noreplace) %attr(0600,apache,apache) %{_sysconfdir}/%{name_root}/config.php
183     %{_sysconfdir}/%{name_root}/ca-bundle.crt
184 neoclust 1036847
185 joequant 1562464 %{_datadir}/%{name_root}
186 neoclust 1045477
187 joequant 1562464 %dir %attr(0755,apache,apache) %{_localstatedir}/lib/%{name_root}
188     %dir %attr(0755,apache,apache) %{_localstatedir}/lib/%{name_root}/apps
189     %dir %attr(0750,apache,apache) %{_localstatedir}/lib/%{name_root}/data
190 neoclust 1036847
191 guillomovitch 1153655 %config(noreplace) %{webappconfdir}/nextcloud.conf
192     %config(noreplace) %{webappconfdir}/nextcloud.inc
193 joequant 1562464 %config(noreplace) %{_sysconfdir}/cron.d/%{name_root}
194     %config(noreplace) %{_sysconfdir}/php-fpm.d/%{name_root}.conf
195 neoclust 1045479
196 guillomovitch 1153655 %files mysql
197     %doc README.mysql
198    
199     %files postgresql
200     %doc README.postgresql
201    
202     %files sqlite

  ViewVC Help
Powered by ViewVC 1.1.30