Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
devel:languages:perl
request-tracker
request-tracker.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File request-tracker.spec of Package request-tracker
# # spec file for package request-tracker # # Copyright (c) 2024 SUSE LLC # Author: Lars Vogdt # # 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/ # #Compat macro for new _fillupdir macro introduced in Nov 2017 %if ! %{defined _fillupdir} %define _fillupdir /var/adm/fillup-templates %endif %if 0%{?suse_version} >= 1230 %bcond_without systemd %else %bcond_with systemd %endif Name: request-tracker Summary: RT: Request Tracker License: GPL-2.0-or-later Group: Productivity/Networking/Web/Utilities Version: 5.0.7 Release: 0 URL: https://bestpractical.com/request-tracker Source0: https://download.bestpractical.com/pub/rt/release/rt-%{version}.tar.gz Source1: rcrequest-tracker Source2: logrotate.%{name} Source3: suse.de-request-tracker.cron.daily Source4: suse.de-request-tracker.cron.weekly Source5: suse.de-request-tracker.cron.hourly Source6: sysconfig.%{name} Source7: apache2-fastcgi.conf Source8: apache2-modperl2.conf Source9: rt-clean-mason-cache Source10: request-tracker-rpmlintrc Source11: rt-mysql2pg Source12: README.SUSE Source13: rt-ldapimport.man Source14: rt-clean-mason-cache.man Source15: rt-mysql2pg-contrib.man Source16: request-tracker-prepare.sh Source17: request-tracker.service Source18: README.S3 Source19: README.Dropbox Patch0: enable-build-as-non-root.patch Patch1: request-tracker-use_local_lib.patch BuildArch: noarch AutoReqProv: off PreReq: %fillup_prereq PreReq: apache2 PreReq: apache2-mod_perl PreReq: postfix PreReq: pwdutils %if %{with systemd} BuildRequires: systemd %{?systemd_requires} %else PreReq: %insserv_prereq %endif BuildRequires: perl-macros %{perl_requires} Provides: perl(RT) = %{version} #Requires: droid-fonts Requires: %{name}-db-backend == %{version} Requires: logrotate Recommends: %{name}-db-mysql == %{version} # requirements from http://wiki.bestpractical.com/view/ManualRequirements Requires: %{name}-mailgate = %{version} #Requires: apache2-mod_fcgid Requires: apache2-mod_perl Requires: perl-base # same list as in BuildRequires below: Requires: gpg2 Requires: perl(Apache::DBI) Requires: perl(Apache::Session) >= 1.53 Requires: perl(CGI) >= 3.38 Requires: perl(CGI::Cookie) >= 0.76 Requires: perl(CGI::Emulate::PSGI) Requires: perl(CGI::Fast) Requires: perl(CGI::PSGI) Requires: perl(CSS::Minifier::XS) Requires: perl(CSS::Squish) >= 0.06 Requires: perl(Cache::Simple::TimedExpiry) Requires: perl(Calendar::Simple) Requires: perl(Class::Accessor) >= 0.34 Requires: perl(Class::Accessor::Chained) Requires: perl(Class::ReturnValue) >= 0.40 Requires: perl(Convert::Color) Requires: perl(Crypt::Eksblowfish) Requires: perl(Crypt::SSLeay) Requires: perl(Crypt::X509) Requires: perl(DBD::SQLite) Requires: perl(DBI) >= 1.37 Requires: perl(DBIx::SearchBuilder) >= 1.76 Requires: perl(Data::GUID) Requires: perl(Data::ICal) Requires: perl(Data::UUID) >= 1.148 Requires: perl(Date::Extract) >= 0.07 Requires: perl(Date::Manip) Requires: perl(DateTime::Format::Natural) Requires: perl(Devel::StackTrace) >= 1.19 Requires: perl(Digest::MD5) >= 2.27 Requires: perl(Digest::base) Requires: perl(Email::Address) >= 1.897 Requires: perl(Email::Address::List) >= 0.06 Requires: perl(Encode) >= 2.64 Requires: perl(Errno) Requires: perl(FCGI) Requires: perl(FCGI::ProcManager) Requires: perl(File::Glob) Requires: perl(File::ShareDir) Requires: perl(File::Spec) >= 0.8 Requires: perl(File::Temp) >= 0.19 Requires: perl(GD) Requires: perl(GD::Graph) >= 1.56 Requires: perl(GD::Text) Requires: perl(GnuPG::Interface) Requires: perl(GraphViz) Requires: perl(HTML::Entities) Requires: perl(HTML::FormatText) Requires: perl(HTML::FormatText::WithLinks) Requires: perl(HTML::FormatText::WithLinks::AndTables) Requires: perl(HTML::Mason) >= 1.36 Requires: perl(HTML::Mason::PSGIHandler) Requires: perl(HTML::Quoted) Requires: perl(HTML::RewriteAttributes) >= 0.05 Requires: perl(HTML::Scrubber) >= 0.08 Requires: perl(HTML::TreeBuilder) Requires: perl(HTTP::Server::Simple) >= 0.34 Requires: perl(HTTP::Server::Simple::Mason) >= 0.09 Requires: perl(IPC::Run) Requires: perl(IPC::Run3) Requires: perl(JSON) Requires: perl(JavaScript::Minifier) Requires: perl(JavaScript::Minifier::XS) Requires: perl(LWP) Requires: perl(LWP::Protocol::https) Requires: perl(LWP::UserAgent) Requires: perl(Locale::Maketext) >= 1.06 Requires: perl(Locale::Maketext::Fuzzy) Requires: perl(Locale::Maketext::Lexicon) >= 0.32 Requires: perl(Log::Dispatch) >= 2.30 Requires: perl(MIME::Entity) >= 5.504 Requires: perl(MIME::Types) Requires: perl(Mail::Header) >= 2.12 Requires: perl(Mail::Mailer) >= 1.57 Requires: perl(Module::Pluggable) Requires: perl(Module::Refresh) >= 0.03 Requires: perl(Module::Runtime) Requires: perl(Module::Versions::Report) >= 1.05 Requires: perl(Mozilla::CA) Requires: perl(Net::CIDR) Requires: perl(Net::SMTP) Requires: perl(Net::SSL) Requires: perl(Net::Server) Requires: perl(PerlIO::eol) Requires: perl(Plack) >= 1.0002 Requires: perl(Plack::Handler::Starlet) Requires: perl(Pod::Usage) Requires: perl(Regexp::Common) Requires: perl(Regexp::Common::net::CIDR) Requires: perl(Regexp::IPv6) Requires: perl(Role::Basic) Requires: perl(Scalar::Util) Requires: perl(Storable) >= 2.08 Requires: perl(String::ShellQuote) Requires: perl(String::ShellQuote) Requires: perl(Symbol::Global::Name) >= 0.04 Requires: perl(Sys::Syslog) >= 0.16 Requires: perl(Text::Password::Pronounceable) Requires: perl(Text::Quoted) >= 2.07 Requires: perl(Text::Template) >= 1.44 Requires: perl(Text::WikiFormat) >= 0.76 Requires: perl(Text::Wrapper) Requires: perl(Time::HiRes) Requires: perl(Time::ParseDate) Requires: perl(Tree::Simple) >= 1.04 Requires: perl(XML::RSS) >= 1.05 # 5.0 new CORE dependencies Requires: perl(Encode::Detect::Detector) Requires: perl(Encode::HanExtra) Requires: perl(GnuPG::Interface) Requires: perl(HTML::FormatExternal) Requires: perl(HTML::Gumbo) Requires: perl(Module::Path) Requires: perl(Moose) Requires: perl(MooseX::NonMoose) Requires: perl(MooseX::Role::Parameterized) Requires: perl(Parallel::ForkManager) Requires: perl(Path::Dispatcher) >= 1.07 Requires: perl(Text::WordDiff) Requires: perl(Web::Machine) >= 0.12 # 5.0 EXTERNALAUTH dependencies Requires: perl(Net::LDAP) # 5.0 end dependencies Recommends: perl(HTML::Gumbo) >= 0.18 Recommends: perl(HTML::FormatExternal) %if %{with systemd} BuildRequires: systemd %{?systemd_requires} %else Requires: cron BuildRequires: cron %endif BuildRequires: apache2-devel BuildRequires: fdupes BuildRequires: gd-devel BuildRequires: gpg2 # 4.0.1 BuildRequires: perl(CGI::Emulate::PSGI) BuildRequires: perl(CGI::PSGI) BuildRequires: perl(Convert::Color) BuildRequires: perl(Data::UUID) >= 1.148 BuildRequires: perl(FCGI::ProcManager) BuildRequires: perl(GraphViz) BuildRequires: perl(HTML::Mason::PSGIHandler) BuildRequires: perl(HTML::Quoted) BuildRequires: perl(IPC::Run) BuildRequires: perl(IPC::Run3) BuildRequires: perl(JSON) BuildRequires: perl(JavaScript::Minifier) BuildRequires: perl(Net::CIDR) BuildRequires: perl(Plack) >= 1.0002 BuildRequires: perl(Plack::Handler::Starlet) BuildRequires: perl(Regexp::Common::net::CIDR) BuildRequires: perl(Regexp::IPv6) BuildRequires: perl(Text::Password::Pronounceable) # 4.4.1 BuildRequires: perl(Business::Hours) BuildRequires: perl(CSS::Minifier::XS) BuildRequires: perl(JavaScript::Minifier::XS) BuildRequires: perl(Net::IP) BuildRequires: perl(Scope::Upper) # CLI dependencies BuildRequires: perl(Getopt::Long) BuildRequires: perl(HTTP::Request::Common) BuildRequires: perl(LWP) BuildRequires: perl(LWP::Protocol::https) BuildRequires: perl(Term::ReadKey) BuildRequires: perl(Term::ReadLine) BuildRequires: perl(Text::ParseWords) # CORE dependencies BuildRequires: perl(Apache::DBI) BuildRequires: perl(CSS::Squish) >= 0.06 BuildRequires: perl(Cache::Simple::TimedExpiry) BuildRequires: perl(Calendar::Simple) BuildRequires: perl(Class::ReturnValue) >= 0.40 BuildRequires: perl(Crypt::Eksblowfish) BuildRequires: perl(DBI) >= 1.37 BuildRequires: perl(DBIx::SearchBuilder) >= 1.65 BuildRequires: perl(Data::GUID) BuildRequires: perl(Data::Page) BuildRequires: perl(Date::Extract) BuildRequires: perl(Date::Manip) BuildRequires: perl(DateTime::Format::Natural) BuildRequires: perl(Devel::StackTrace) >= 1.19 BuildRequires: perl(Digest::MD5) >= 2.27 BuildRequires: perl(Digest::base) BuildRequires: perl(Email::Address::List) >= 0.06 BuildRequires: perl(Encode) >= 2.64 BuildRequires: perl(File::Glob) BuildRequires: perl(File::ShareDir) BuildRequires: perl(File::Spec) >= 0.8 BuildRequires: perl(File::Temp) >= 0.19 BuildRequires: perl(HTML::Entities) BuildRequires: perl(HTML::FormatText::WithLinks) BuildRequires: perl(HTML::FormatText::WithLinks::AndTables) BuildRequires: perl(HTML::Scrubber) >= 0.08 BuildRequires: perl(Locale::Maketext) >= 1.06 BuildRequires: perl(Locale::Maketext::Fuzzy) BuildRequires: perl(Locale::Maketext::Lexicon) >= 0.32 BuildRequires: perl(Log::Dispatch) >= 2.30 BuildRequires: perl(MIME::Entity) >= 5.504 BuildRequires: perl(Mail::Header) >= 2.12 BuildRequires: perl(Mail::Mailer) >= 1.57 BuildRequires: perl(Module::Pluggable) BuildRequires: perl(Module::Refresh) >= 0.03 BuildRequires: perl(Module::Versions::Report) >= 1.05 BuildRequires: perl(Parallel::ForkManager) BuildRequires: perl(Regexp::Common) BuildRequires: perl(Role::Basic) BuildRequires: perl(Scalar::Util) BuildRequires: perl(Symbol::Global::Name) >= 0.04 BuildRequires: perl(Sys::Syslog) >= 0.16 BuildRequires: perl(Text::Quoted) >= 2.07 BuildRequires: perl(Text::Template) >= 1.44 BuildRequires: perl(Text::Wrapper) BuildRequires: perl(Time::HiRes) BuildRequires: perl(Time::ParseDate) BuildRequires: perl(Tree::Simple) >= 1.04 # 4.4.1 Requires: perl(Business::Hours) Requires: perl(CSS::Minifier::XS) Requires: perl(Data::Page) Requires: perl(JavaScript::Minifier::XS) Requires: perl(Net::IP) Requires: perl(Scope::Upper) # 5.0 new CORE dependencies BuildRequires: perl(Encode::Detect::Detector) BuildRequires: perl(Encode::HanExtra) BuildRequires: perl(GnuPG::Interface) BuildRequires: perl(HTML::FormatExternal) BuildRequires: perl(HTML::Gumbo) BuildRequires: perl(Module::Path) BuildRequires: perl(Moose) BuildRequires: perl(MooseX::NonMoose) BuildRequires: perl(MooseX::Role::Parameterized) BuildRequires: perl(Path::Dispatcher) >= 1.07 BuildRequires: perl(Text::WordDiff) BuildRequires: perl(Web::Machine) >= 0.12 # 5.0 EXTERNALAUTH dependencies BuildRequires: perl(Net::LDAP) # 5.0 end dependencies # 5.0.7 dependencies BuildRequires: perl(GraphViz2) Requires: perl(GraphViz2) # End 5.0.7 dependencies BuildRequires: perl(Email::Address) >= 1.897 BuildRequires: perl(Module::Runtime) # DASHBOARDS dependencies BuildRequires: perl(HTML::RewriteAttributes) >= 0.4 BuildRequires: perl(MIME::Types) # FASTCGI dependencies BuildRequires: perl(CGI::Fast) # some other package provides perl(CGI), but we really need the correct package BuildRequires: perl(CGI) >= 3.38 Requires: perl(CGI) >= 3.38 BuildRequires: perl(FCGI) Requires: perl(FCGI) # GD dependencies BuildRequires: perl(GD) BuildRequires: perl(GD::Graph) >= 1.56 BuildRequires: perl(GD::Text) # GPG dependencies BuildRequires: perl(GnuPG::Interface) BuildRequires: perl(PerlIO::eol) # ICAL dependencies BuildRequires: perl(Class::Accessor) >= 0.34 BuildRequires: perl(Data::ICal) #>= 0.34 BuildRequires: perl(Class::Accessor::Chained) # MAILGATE dependencies BuildRequires: perl(Crypt::SSLeay) BuildRequires: perl(HTML::FormatText) BuildRequires: perl(HTML::TreeBuilder) BuildRequires: perl(LWP::UserAgent) BuildRequires: perl(Mozilla::CA) BuildRequires: perl(Net::SSL) BuildRequires: perl(Pod::Usage) # MASON dependencies BuildRequires: perl(Storable) >= 2.08 #BuildRequires: perl-CSS-Squish >= 0.06 # duplicate BuildRequires: perl(Apache::Session) >= 1.53 BuildRequires: perl(Errno) #BuildRequires: perl(Devel::StackTrace) >= 1.19 # duplicate BuildRequires: perl(CGI::Cookie) >= 0.76 BuildRequires: perl(HTML::Mason) >= 1.36 BuildRequires: perl(Text::WikiFormat) >= 0.76 BuildRequires: perl(XML::RSS) >= 1.05 #BuildRequires: perl(Digest::MD5) >= 2.27 # duplicate # MYSQL dependencies BuildRequires: perl(DBD::mysql) >= 2.1018 # SMTP dependencies BuildRequires: perl(Net::SMTP) # STANDALONE dependencies BuildRequires: perl(HTTP::Server::Simple) >= 0.34 BuildRequires: perl(HTTP::Server::Simple::Mason) >= 0.09 BuildRequires: perl(Net::Server) # SMIME dependencies BuildRequires: perl(Crypt::X509) BuildRequires: perl(String::ShellQuote) # SQLite dependencies BuildRequires: perl(DBD::SQLite) >= 1.72 # recommended packages # Running with the internal HTML converter can result in performance issues with some HTML. # Install one of the following utilities with your package manager to improve performance # with an external tool: w3m, elinks, links, html2text, lynx Recommends: w3m BuildRoot: %{_tmppath}/%{name}-%{version}-build %description Request Tracker (RT) is an enterprise-grade ticketing system which enables a group of people to intelligently and efficiently manage tasks, issues, and requests submitted by a community of users. It features a web, email and command-line interfaces. Written in object-oriented Perl, RT is a high-level, portable, platform independent system that eases collaboration within organizations and makes it easy for them to take care of their customers. RT manages key tasks such as the identification, prioritization, assignment, resolution and notification required by enterprise-critical applications including project management, help desk, NOC ticketing, CRM and software development. %define webdir %{_datadir}/%{name} %define rt_libdir %{perl_vendorlib} %define rt_wwwdir %{webdir}/html %define rt_logdir %{_var}/log/%{name} %define rt_cachedir %{_var}/cache/%{name} %define rt_localstatedir %{_var}/lib/%{name} %define rt_sbindir %{_sbindir} %define rt_bindir %{_bindir} %define rt_mandir %{_mandir} %define rt_sysconfdir %{_sysconfdir}/%{name} %define rt_user rt %define rt_group rt %define www_user wwwrun %define www_group www %package mailgate Summary: Mail gateway for Request Tracker Group: Productivity/Networking/Web/Utilities Requires: smtp_daemon Requires: perl(Getopt::Long) Requires: perl(HTML::FormatText) Requires: perl(HTML::TreeBuilder) Requires: perl(HTTP::Request::Common) Requires: perl(LWP) Requires: perl(LWP::Protocol::https) Requires: perl(Pod::Usage) Requires: perl(Term::ReadKey) Requires: perl(Term::ReadLine) Requires: perl(Text::ParseWords) %description mailgate This package provides support for injecting tickets into Request Tracker from a mail server via rt-mailgate. It may be installed onto any machine where you want to use the mail gateway interface. %package db-oracle Summary: Oracle database backend for Request Tracker Group: Productivity/Networking/Web/Utilities Requires: perl-DBD-Oracle %description db-oracle This package provides dependencies and support for using Request Tracker with an Oracle database. %package db-postgres Summary: PostgreSQL database backend for Request Tracker Group: Productivity/Networking/Web/Utilities PreReq: postgresql Recommends: postgresql-backupscript Requires: %{name} = %{version} Requires: perl(DBD::Pg) Recommends: postgresql-server Provides: %{name}-db-backend = %{version}-%{release} %description db-postgres This package provides dependencies and support for using Request Tracker with a PostgreSQL database. %package db-mysql Summary: MySQL database backend for Request Tracker Group: Productivity/Networking/Web/Utilities PreReq: mysql Recommends: mysql-backupscript Requires: %{name} = %{version} Requires: perl(DBD::mysql) >= 2.1018 Recommends: mysql-community-server Provides: %{name}-db-backend = %{version}-%{release} %description db-mysql This package provides dependencies and support for using Request Tracker with a MySQL database. %package db-sqlite Summary: SQLite database backend for Request Tracker Group: Productivity/Networking/Web/Utilities PreReq: sqlite3 Requires: %{name} = %{version} Requires: perl(DBD::SQLite) Provides: %{name}-db-backend = %{version}-%{release} %description db-sqlite This package provides dependencies and support for using Request Tracker with a SQLite database. Please note: SQLite is not recommended for production use. %package attachment-storage-S3 Summary: Amazon S3 attachment storage Group: Productivity/Networking/Web/Utilities Requires: perl(Amazon::S3) Provides: RT-attachment-storage = %{version}-%{release} %description attachment-storage-S3 This storage option places attachments in the S3 cloud file storage service. The files are de-duplicated when they are saved; as such, if the same file appears in multiple transactions, only one copy will be stored in S3. Files in S3 must not be modified or removed; doing so may cause internal inconsistency. It is also important to ensure that the S3 account used maintains sufficient funds for your RT's storage and bandwidth needs. %package attachment-storage-Dropbox Summary: Dropbox attachment storage Group: Productivity/Networking/Web/Utilities Requires: perl(File::Dropbox) >= 0.7 Provides: RT-attachment-storage = %{version}-%{release} %description attachment-storage-Dropbox This storage option places attachments in the Dropbox shared file service. The files are de-duplicated when they are saved; as such, if the same file appears in multiple transactions, only one copy will be stored in Dropbox. Files in Dropbox must not be modified or removed; doing so may cause internal inconsistency. It is also important to ensure that the Dropbox account used has sufficient space for the attachments, and to monitor its space usage. %prep %autosetup -n rt-%{version} -p1 # remove temporary (left over) files/dirs: rm -rf share/static/RichText/skins/bootstrapck/.temp # install README files install -m 0644 %{S:12} README.SUSE install -m 0644 %{S:18} README.S3 install -m 0644 %{S:19} README.Dropbox sed -i "s|__vendorperl__|%{perl_vendorlib}|g" sbin/* bin/* # prepare scripts/cron jobs for installation for source in %{SOURCE1} %{SOURCE3} %{SOURCE4} %{SOURCE5} %{SOURCE6} %{SOURCE16} %{SOURCE17}; do sed -e "s|__RT_CACHEDIR__|%{rt_cachedir}|g; \ s|__MASONSTATEDIR__|%{rt_cachedir}/mason_data|g; \ s|__SESSIONSTATEDIR__|%{rt_cachedir}/session_data|g; \ s|__RT_BINDIR__|%{rt_bindir}|g; \ s|__RT_SBINDIR__|%{rt_sbindir}|g; \ s|__RT_LOGDIR__|%{rt_logdir}|g; \ s|__RT_USER__|%{rt_user}|g; \ s|__RT_GROUP__|%{rt_group}|g; \ s|__WWW_USER__|%{www_user}|g; \ s|__WWW_GROUP__|%{www_group}|g; \ s|__RT_SBINDIR__|%{rt_sbindir}|g; \ s|__RT_LOCALSTATEDIR__|%{rt_localstatedir}|g" \ "$source" > $(basename "$source") done # fix documentation for the openSUSE layout for file in $(find docs/ -type f) README* ; do sed -i "s|/opt/rt4/sbin|%{rt_sbindir}|g; \ s|/opt/rt4/share/html|%{rt_wwwdir}|g; \ s|/opt/rt4/var|%{rt_cachedir}|g; \ s|/opt/rt4/lib|%{rt_libdir}|g; \ s|/opt/rt4/local|%{webdir}/local|g; \ s|etc/upgrade|%{webdir}/etc/upgrade|g; \ s|/opt/rt4/bin|%{rt_bindir}|g;" \ $file done # Propagate rpm's directories to config.layout cat << \EOF >> config.layout # openSUSE directory layout. <Layout openSUSE> Prefix: %{webdir} exec_prefix: ${prefix} bindir: %{rt_bindir} sbindir: %{rt_sbindir} sysconfdir: %{rt_sysconfdir} mandir: %{rt_mandir} plugindir: ${prefix}/plugins libdir: %{rt_libdir} datadir: ${prefix}/share htmldir: %{rt_wwwdir} fontdir: ${datadir}/fonts lexdir: ${datadir}/po staticdir: ${datadir}/static manualdir: ${prefix}/doc localstatedir: %{rt_localstatedir} logfiledir: %{rt_logdir} masonstatedir: %{rt_cachedir}/mason_data sessionstatedir: %{rt_cachedir}/session_data customdir: ${prefix}/local custometcdir: %{rt_sysconfdir}/local/etc customhtmldir: ${customdir}/html customlexdir: ${customdir}/po customstaticdir: ${customdir}/static customlibdir: ${customdir}/lib customplugindir: ${customdir}/plugins </Layout> EOF # fix env interpreter script for file in etc/upgrade/upgrade-mysql-schema.pl ; do sed -i "s|/usr/bin/env perl|%{_bindir}/perl|g" "$file" done %build %configure \ --prefix=%{webdir} \ --enable-layout="openSUSE" \ --enable-graphviz \ --enable-gd \ --enable-gpg \ --enable-smime \ --enable-externalauth \ --with-bin-owner="root" \ --with-libs-owner="root" \ --with-libs-group="root" \ --with-rt-group="%{rt_group}" \ --with-web-user="%{www_user}" \ --with-web-group="%{www_group}" \ --with-web-handler=fastcgi,modperl2,standalone \ --with-db-database="rt4" \ --with-db-host="localhost" \ --with-db-rt-user="rt" \ --with-db-rt-pass="rt_pass" \ --with-db-type="mysql" \ --with-rt-group="rt" make testdeps make %{?_smp_mflags} %install %makeinstall # create missing directories mkdir -p %{buildroot}/%{rt_localstatedir} mkdir -p %{buildroot}/%{rt_logdir} mkdir -p %{buildroot}/%{rt_cachedir}/{session_data,mason_data} # Generate man-pages mkdir -p %{buildroot}/%{rt_mandir}/man1 # Added missing man page install -m 0644 %{S:13} %{buildroot}/%{rt_mandir}/man1/rt-ldapimport.1 install -m 0644 %{S:14} %{buildroot}/%{rt_mandir}/man1/rt-clean-mason-cache.1 install -m 0644 %{S:15} %{buildroot}/%{rt_mandir}/man1/rt-mysql2pg-contrib.1 for binary in %{buildroot}/%{_bindir}/* %{buildroot}/%{_sbindir}/* ; do MANNAME=$(basename ${binary}.1) # this fails on 13.1 # [ $MANNAME = "rt-validate-aliases.1" ] && break test -f %{buildroot}/%{rt_mandir}/man1/$MANNAME || %{_bindir}/pod2man $binary > %{buildroot}/%{rt_mandir}/man1/$MANNAME done %if %{with systemd} install -Dm644 request-tracker.service %{buildroot}/%{_unitdir}/request-tracker.service ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rc%{name} # # install systemd timers # # rt-email-digest-daily cat << \EOF >> %{buildroot}%{_unitdir}/rt-email-digest-daily.timer [Unit] Description=Request Tracker Email digest daily [Timer] OnBootSec=1h OnCalendar=daily AccuracySec=24h Persistent=true [Install] WantedBy=timers.target EOF cat << \EOF >> %{buildroot}%{_unitdir}/rt-email-digest-daily.service [Unit] Description=Daily non-interactive Request Tracker Email digest [Service] Type=oneshot ExecStart=%{rt_sbindir}/rt-email-digest -m daily EOF # rt-email-digest-weekly cat << \EOF >> %{buildroot}%{_unitdir}/rt-email-digest-weekly.timer [Unit] Description=Request Tracker Email digest weekly [Timer] OnBootSec=1h OnCalendar=weekly AccuracySec=24h Persistent=true [Install] WantedBy=timers.target EOF cat << \EOF >> %{buildroot}%{_unitdir}/rt-email-digest-weekly.service [Unit] Description=Weekly non-interactive Request Tracker Email digest [Service] Type=oneshot ExecStart=%{rt_sbindir}/rt-email-digest -m weekly EOF # rt-email-dashboard cat << \EOF >> %{buildroot}%{_unitdir}/rt-email-dashboard.timer [Unit] Description=Request Tracker Email Dashboard update hourly [Timer] OnBootSec=1h OnCalendar=hourly Persistent=true [Install] WantedBy=timers.target EOF cat << \EOF >> %{buildroot}%{_unitdir}/rt-email-dashboard.service [Unit] Description=Hourly Request Tracker Email dashboard update [Service] Type=oneshot ExecStart=%{rt_sbindir}/rt-email-dashboards EOF %else # install init script that creates needed directories on demand during boot install -Dm755 rcrequest-tracker %{buildroot}/%{_sysconfdir}/init.d/%{name} mkdir -p %{buildroot}/%{_sbindir} && pushd %{buildroot}/%{_sbindir} ln -s %{_sysconfdir}/init.d/%{name} rc%{name} popd # install cron jobs for i in cron.daily cron.weekly cron.hourly ; do mkdir -p %{buildroot}/%{_sysconfdir}/$i mv suse.de-request-tracker.$i %{buildroot}/%{_sysconfdir}/$i/ chmod +x %{buildroot}/%{_sysconfdir}/$i/* done %endif # install README for db-backend docs cat << \EOF >> README.db-backend This package provides dependencies and support for using Request Tracker with the desired database. = New installation = For the initial setup, please follow these steps: 1) Create database and database user For mysql, this looks like (rt4 == your_database; rt_pass == your_password; rt = your_rt_user): ~# mysqladmin create rt4 ~# mysql -u root mysql> grant all on rt4.* to 'rt'@'localhost' identified by 'rt_pass'; mysql> flush privileges; mysql> quit 2) Create database tables The schemata for the RT tables are placed in %{} For mysql with 'rt4' being your RT database, the commandline to create the tables looks like: ~# mysql rt4 < /etc/request-tracker/schema.mysql 3) Start the rt-server Make sure that there is no other service running on port 80 on your machine (like apache) - and start the stand-alone rt-server: ~# /usr/sbin/rt-server 4) Do the needed initial setup via the WebUI: Start your browser and visit the URL http://0:80/ to configure RT and initialize your database. = Existing installation = If this is an existing RT installation, consult %{_defaultdocdir}/%{name}/README, beginning from step 6b EOF # install cleanup script for Mason Cache install -Dm755 %{SOURCE9} %{buildroot}%{rt_sbindir}/rt-clean-mason-cache sed -i "s|__RT_CACHEDIR__|%{rt_cachedir}|g; s|__SYSCONFDIR__|%{_sysconfdir}|g" %{buildroot}%{rt_sbindir}/rt-clean-mason-cache # install MySQL to PostgreSQL conversion perl script install -Dm755 %{SOURCE11} %{buildroot}%{rt_sbindir}/rt-mysql2pg-contrib # install logrotate stuff mkdir -p %{buildroot}/%{rt_logdir} mkdir -p %{buildroot}/%{_sysconfdir}/logrotate.d sed -e "s|__RT_LOGDIR__|%{rt_logdir}|g" %{SOURCE2} > %{buildroot}/%{_sysconfdir}/logrotate.d/%{name} %if 0%{?suse_version} > 01210 echo " su %{rt_user} %{rt_group}" >> %{buildroot}/%{_sysconfdir}/logrotate.d/%{name} %endif echo "}" >> %{buildroot}/%{_sysconfdir}/logrotate.d/%{name} # install upgrade files mkdir -p %{buildroot}/%{webdir}/etc/ cp -r etc/upgrade %{buildroot}/%{webdir}/etc/ rm %{buildroot}/%{webdir}/etc/upgrade/*.in find %{buildroot}/%{webdir}/etc/upgrade -size 0b -exec rm {} \; find %{buildroot}/%{webdir}/etc/upgrade -name "schema.*" -exec chmod 644 {} \; find %{buildroot}/%{webdir}/etc/upgrade -name "acl.*" -exec chmod 644 {} \; find %{buildroot}/%{webdir}/etc/upgrade -name "*.pl" -exec chmod 750 {} \; # remove duplicate files %fdupes %{buildroot}/%{webdir} %fdupes %{buildroot}/%{rt_sysconfdir} # remove zero size config files find %{buildroot}%{rt_sysconfdir}/upgrade/ -size 0 -delete # install helper script install -Dm755 request-tracker-prepare.sh %{buildroot}/%{rt_sbindir}/request-tracker-prepare.sh # install sysconfig file mkdir -p %{buildroot}%{_fillupdir} mv sysconfig.%{name} %{buildroot}/%{_fillupdir}/ # install apache configs mkdir -p %{buildroot}/%{rt_sysconfdir}/apache2 install -m644 %{SOURCE7} %{buildroot}/%{rt_sysconfdir}/apache2/ install -m644 %{SOURCE8} %{buildroot}/%{rt_sysconfdir}/apache2/ # install GnuPG and SMIME directories mkdir -p %{buildroot}%{rt_localstatedir}/data/{gpg,smime,RT-Shredder} %clean rm -rf %{buildroot} %pre # in case of a fresh install, we do a bit of setup if [ $1 -eq 1 ]; then # set up user credentials %{_sbindir}/groupadd -r %{rt_group} 2>/dev/null || : %{_sbindir}/useradd -r -g %{rt_group} -d %{webdir} -s /sbin/nologin -c "Request Tracker User" %{rt_user} 2>/dev/null || : %if 0%{?suse_version} > 01210 %{_sbindir}/usermod -a -G %{rt_group} %{www_user} 2>/dev/null || : %else %{_sbindir}/groupmod -A %{www_group} %{rt_group} 2>/dev/null || : %endif %if %{with systemd} %service_add_pre %{name}.service %service_add_pre apache2.service %service_add_pre mysql.service %service_add_pre postfix.service %service_add_pre rt-email-dashboard.timer rt-email-digest-daily.timer rt-email-digest-weekly.timer %else %fillup_and_insserv -f apache2 %fillup_and_insserv -f mysql %fillup_and_insserv -f postfix %endif fi %preun %if %{with systemd} %service_del_preun apache2.service %service_del_preun %{name}.service %service_del_preun rt-email-dashboard.timer rt-email-digest-daily.timer rt-email-digest-weekly.timer %else %restart_on_update apache2 %stop_on_removal %{name} %endif %post # enable perl in apache config if [ -x %{_sbindir}/a2enmod ]; then if grep -q perl %{_sysconfdir}/sysconfig/apache2 1>&2 2>/dev/null; then %{_sbindir}/a2enmod perl >/dev/null fi fi if [ $1 -eq 2 ]; then echo "Please consult %{_defaultdocdir}/%{name}/README.SuSE and %{_defaultdocdir}/%{name}/README, beginning from step 6b." echo "NOTE: %{_var}/run/%{name} has been changed to %{_var}/lib/%{name}...you'll need to migrate said data accordingly" fi %if %{with systemd} %service_add_post apache2 %service_add_post %{name}.service %service_add_post rt-email-dashboard.timer rt-email-digest-daily.timer rt-email-digest-weekly.timer %fillup_only %else %restart_on_update apache2 %restart_on_update %{name} %fillup_and_insserv %{name} %endif %postun %if %{with systemd} %service_del_postun %{name}.service %service_del_postun rt-email-dashboard.timer rt-email-digest-daily.timer rt-email-digest-weekly.timer %else %{insserv_cleanup} %endif %files %defattr(-,root,root) %doc README.md README.Oracle README.SUSE %if 0%{?suse_version} >= 01500 %license COPYING %else %doc COPYING %endif %doc %{rt_mandir}/man1/* %dir %{webdir} %dir %{rt_sysconfdir} %dir %{perl_vendorlib}/RT %attr(-,%{rt_user},%{www_group}) %dir %{rt_cachedir} %attr(-,%{rt_user},%{www_group}) %dir %{rt_cachedir}/session_data %attr(-,%{rt_user},%{www_group}) %dir %{rt_cachedir}/mason_data %attr(-,%{rt_user},%{www_group}) %dir %{rt_cachedir}/mason_data/cache %attr(-,%{rt_user},%{www_group}) %dir %{rt_cachedir}/mason_data/obj %attr(0775,%{rt_user},%{www_group}) %dir %{rt_logdir} %attr(-,%{rt_user},%{rt_group}) %dir %{rt_localstatedir} %attr(0770,%{rt_user},%{www_group}) %dir %{rt_localstatedir}/data %attr(0770,%{rt_user},%{www_group}) %dir %{rt_localstatedir}/data/gpg %attr(0770,%{rt_user},%{www_group}) %dir %{rt_localstatedir}/data/smime %attr(0770,%{rt_user},%{www_group}) %dir %{rt_localstatedir}/data/RT-Shredder %config %{rt_sysconfdir}/cpanfile %config(noreplace) %{rt_sysconfdir}/initialdata %config(noreplace) %{rt_sysconfdir}/RT_SiteConfig.d %config(noreplace) %{rt_sysconfdir}/apache2 %config(noreplace) %{rt_sysconfdir}/local %config(noreplace) %{rt_sysconfdir}/upgrade %exclude %{rt_sysconfdir}/schema.* %exclude %{rt_sysconfdir}/acl.* %attr(-,root,%{www_group}) %config %{rt_sysconfdir}/RT_Config.pm %attr(-,root,%{www_group}) %config %{rt_sysconfdir}/RT_SiteConfig.pm %config(noreplace) %{_sysconfdir}/logrotate.d/%{name} %if %{with systemd} %{_unitdir}/request-tracker.service %{_unitdir}/rt-email-digest-daily.service %{_unitdir}/rt-email-digest-daily.timer %{_unitdir}/rt-email-digest-weekly.service %{_unitdir}/rt-email-digest-weekly.timer %{_unitdir}/rt-email-dashboard.service %{_unitdir}/rt-email-dashboard.timer %else %{_sysconfdir}/init.d/%{name} %config %{_sysconfdir}/cron.*/* %endif %{rt_sbindir}/* %exclude %{rt_sbindir}/rt-mysql2pg-contrib %{rt_bindir}/* %exclude %{rt_bindir}/rt-mailgate %exclude %{rt_mandir}/man1/rt-mailgate.1* %exclude %{rt_mandir}/man1/rt-mysql2pg-contrib.1* %{perl_vendorlib}/RT.pm %{perl_vendorlib}/RT/* %{webdir}/* %{_fillupdir}/sysconfig.%{name} %files mailgate %defattr(-,root,root,-) %if 0%{?suse_version} >= 01500 %license COPYING %else %doc COPYING %endif %{rt_bindir}/rt-mailgate %{rt_mandir}/man1/rt-mailgate* %files db-postgres %defattr(-,root,root) %doc README.db-backend %{rt_sbindir}/rt-mysql2pg-contrib %doc %{rt_mandir}/man1/rt-mysql2pg-contrib.1* %config %{rt_sysconfdir}/acl.Pg %config %{rt_sysconfdir}/schema.Pg %files db-mysql %defattr(-,root,root) %doc README.db-backend %config %{rt_sysconfdir}/acl.mysql %config %{rt_sysconfdir}/schema.mysql %files db-sqlite %defattr(-,root,root) %doc README.db-backend %config %{rt_sysconfdir}/schema.SQLite %files db-oracle %defattr(-,root,root) %doc README.db-backend %config %{rt_sysconfdir}/acl.Oracle %config %{rt_sysconfdir}/schema.Oracle %files attachment-storage-S3 %defattr(-,root,root) %doc README.S3 %files attachment-storage-Dropbox %defattr(-,root,root) %doc README.Dropbox %changelog
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor