1 |
commit: 4e55823065367473d989d9b71ee5d170cec739a8 |
2 |
Author: Stefan G. Weichinger <office <AT> oops <DOT> co <DOT> at> |
3 |
AuthorDate: Tue Mar 28 08:18:33 2017 +0000 |
4 |
Commit: Göktürk Yüksek <gokturk <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Apr 9 22:55:24 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4e558230 |
7 |
|
8 |
www-apps/otrs-5.0.18: version bump |
9 |
|
10 |
www-apps/otrs/Manifest | 1 + |
11 |
www-apps/otrs/otrs-5.0.18.ebuild | 153 +++++++++++++++++++++++++++++++++++++++ |
12 |
2 files changed, 154 insertions(+) |
13 |
|
14 |
diff --git a/www-apps/otrs/Manifest b/www-apps/otrs/Manifest |
15 |
index a6d6a4a710b..97de544cda9 100644 |
16 |
--- a/www-apps/otrs/Manifest |
17 |
+++ b/www-apps/otrs/Manifest |
18 |
@@ -1 +1,2 @@ |
19 |
DIST otrs-5.0.16.tar.bz2 19417591 SHA256 ddec039990c1bdfc27299ab175eff3e1665aa99ba48050f7f2dde480b28f4029 SHA512 326ebc97b689ce05c33a4f8e5587b891029c168544ab6bea4e5b112b2c75527a605689fd957d7acdebf18e331176db727cca4c87244f22cfdb9b9e4e0735b6c4 WHIRLPOOL 4dfe35d1c3cd940523219dafae5f62447e6bc363e601b4fc98fdf46d09731dbf61ddb109d5b368af6fc2b25ab44f18e455dbd9de2e00d367363c34972af221b2 |
20 |
+DIST otrs-5.0.18.tar.bz2 20401943 SHA256 32d2a17996a882fb8965e52d92589be1a9a8fb1a15cd47689919e6d1302fe1b4 SHA512 5b228a92f8280b79ed32853f9b0a5b135ee42068faba66267c9772697c3ccd8f2ee965797fe65b8c7d1455f3729fe106d9321a06e444bda8e06f92dac00ab8c1 WHIRLPOOL 35123d1eb33e5abdb5c44edf55fd204df8f4b50fe331ae3f8f2634cdb21ca091e76b8517458595af4f0246eebb399770fc02a54070833ad6dae4dd83b2ad8c11 |
21 |
|
22 |
diff --git a/www-apps/otrs/otrs-5.0.18.ebuild b/www-apps/otrs/otrs-5.0.18.ebuild |
23 |
new file mode 100644 |
24 |
index 00000000000..16e682a03da |
25 |
--- /dev/null |
26 |
+++ b/www-apps/otrs/otrs-5.0.18.ebuild |
27 |
@@ -0,0 +1,153 @@ |
28 |
+# Copyright 1999-2017 Gentoo Foundation |
29 |
+# Distributed under the terms of the GNU General Public License v2 |
30 |
+ |
31 |
+EAPI="6" |
32 |
+ |
33 |
+inherit user systemd |
34 |
+ |
35 |
+DESCRIPTION="OTRS is an Open source Ticket Request System" |
36 |
+HOMEPAGE="https://www.otrs.com/" |
37 |
+SRC_URI="https://ftp.otrs.org/pub/${PN}/${P}.tar.bz2" |
38 |
+ |
39 |
+LICENSE="AGPL-3+" |
40 |
+KEYWORDS="~amd64 ~x86" |
41 |
+IUSE="apache2 fastcgi +gd ldap mod_perl +mysql pdf postgres soap" |
42 |
+SLOT="0" |
43 |
+ |
44 |
+REQUIRED_USE="|| ( mysql postgres )" |
45 |
+ |
46 |
+DEPEND="media-libs/libpng:0" |
47 |
+ |
48 |
+RDEPEND="dev-perl/Apache-Reload |
49 |
+ dev-perl/Archive-Zip |
50 |
+ dev-perl/DBI |
51 |
+ dev-perl/IO-Socket-SSL |
52 |
+ dev-perl/JSON-XS |
53 |
+ dev-perl/LWP-UserAgent-Determined |
54 |
+ dev-perl/Mail-POP3Client |
55 |
+ dev-perl/Mail-IMAPClient |
56 |
+ >dev-perl/Net-DNS-0.60 |
57 |
+ dev-perl/Template-Toolkit |
58 |
+ dev-perl/Text-CSV_XS |
59 |
+ dev-perl/TimeDate |
60 |
+ dev-perl/XML-Parser |
61 |
+ dev-perl/YAML-LibYAML |
62 |
+ apache2? ( |
63 |
+ mod_perl? ( |
64 |
+ www-servers/apache:2 |
65 |
+ =www-apache/libapreq2-2* www-apache/mod_perl |
66 |
+ ) |
67 |
+ !fastcgi? ( !mod_perl? ( www-servers/apache:2[suexec] ) ) |
68 |
+ ) |
69 |
+ fastcgi? ( |
70 |
+ dev-perl/FCGI |
71 |
+ virtual/httpd-fastcgi |
72 |
+ ) |
73 |
+ !fastcgi? ( !apache2? ( virtual/httpd-cgi ) ) |
74 |
+ gd? ( |
75 |
+ dev-perl/GD |
76 |
+ dev-perl/GDTextUtil |
77 |
+ dev-perl/GDGraph |
78 |
+ ) |
79 |
+ ldap? ( dev-perl/perl-ldap ) |
80 |
+ mysql? ( dev-perl/DBD-mysql ) |
81 |
+ postgres? ( dev-perl/DBD-Pg ) |
82 |
+ pdf? ( |
83 |
+ >=dev-perl/PDF-API2-0.73 |
84 |
+ virtual/perl-Compress-Raw-Zlib |
85 |
+ ) |
86 |
+ soap? ( |
87 |
+ dev-perl/SOAP-Lite |
88 |
+ !=dev-perl/SOAP-Lite-0.711 |
89 |
+ !=dev-perl/SOAP-Lite-0.712 |
90 |
+ ) |
91 |
+ " |
92 |
+ |
93 |
+OTRS_HOME="/var/lib/otrs" |
94 |
+ |
95 |
+pkg_setup() { |
96 |
+ # The enewuser otrs will fail if apache isn't there, but it's an optional dep |
97 |
+ # so we create the apache user here just in case |
98 |
+ enewgroup apache 81 |
99 |
+ enewuser apache 81 -1 /var/www apache |
100 |
+ enewuser otrs -1 -1 "${OTRS_HOME}" apache |
101 |
+} |
102 |
+ |
103 |
+src_prepare() { |
104 |
+ rm -r "${S}/scripts"/auto_* || die |
105 |
+ |
106 |
+ pushd Kernel >/dev/null || die |
107 |
+ for i in *.dist; do |
108 |
+ cp "${i}" $(basename "${i}" .dist) || die |
109 |
+ done |
110 |
+ popd >/dev/null || die |
111 |
+ |
112 |
+ # Fix broken png file (and see pngfix help for exit codes) |
113 |
+ pngfix -q --out=out.png "${S}/var/httpd/htdocs/skins/Agent/default/img/otrs-verify.png" |
114 |
+ if [[ $? -gt 15 ]]; then |
115 |
+ die "pngfix failed" |
116 |
+ fi |
117 |
+ mv -f out.png "${S}/var/httpd/htdocs/skins/Agent/default/img/otrs-verify.png" || die |
118 |
+ |
119 |
+ sed -i -e "s:/opt/otrs:${EPREFIX%/}${OTRS_HOME}:g" "${S}"/Kernel/Config.pm \ |
120 |
+ || die "sed failed" |
121 |
+ |
122 |
+ sed -i -e "s:/opt/otrs:${EPREFIX%/}${OTRS_HOME}:g" "${S}"/Kernel/Config/Defaults.pm \ |
123 |
+ || die "sed failed" |
124 |
+ |
125 |
+ grep -lR "/opt" "${S}"/scripts | \ |
126 |
+ xargs sed -i -e "s:/opt/otrs:${EPREFIX%/}${OTRS_HOME}:g" \ |
127 |
+ || die "sed failed" |
128 |
+ |
129 |
+ echo "CONFIG_PROTECT=\"${EPREFIX%/}${OTRS_HOME}/Kernel/Config.pm \ |
130 |
+ ${EPREFIX%/}${OTRS_HOME}/Kernel/Config/GenericAgent.pm\"" > "${T}/50${PN}" || die |
131 |
+ |
132 |
+ eapply_user |
133 |
+} |
134 |
+ |
135 |
+# This is too automagic, either einfo telling user or installing to /etc/cron.d/ should be preferred |
136 |
+pkg_config() { |
137 |
+ einfo "Installing cronjobs" |
138 |
+ crontab -u otrs "${EROOT%/}"/usr/share/doc/${PF}/crontab || die |
139 |
+} |
140 |
+ |
141 |
+src_install() { |
142 |
+ dodoc CHANGES.md README* |
143 |
+ |
144 |
+ insinto "${OTRS_HOME}" |
145 |
+ doins -r .fetchmailrc.dist .mailfilter.dist .procmailrc.dist RELEASE \ |
146 |
+ Custom Kernel bin scripts var |
147 |
+ |
148 |
+ cat "${S}"/var/cron/*.dist > "${T}"/crontab || die |
149 |
+ insinto /usr/share/doc/${PF}/ |
150 |
+ doins "${T}"/crontab |
151 |
+ |
152 |
+ local a |
153 |
+ for a in article log pics/images pics/stats pics sessions spool tmp tmp/CacheFileStorable |
154 |
+ do |
155 |
+ keepdir "${OTRS_HOME}/var/${a}" |
156 |
+ done |
157 |
+ doenvd "${T}/50${PN}" |
158 |
+ |
159 |
+ systemd_dounit "${FILESDIR}/otrs.service" |
160 |
+} |
161 |
+ |
162 |
+pkg_postinst() { |
163 |
+ einfo "Setting correct permissions ..." |
164 |
+ /usr/bin/env perl "${EROOT%/}${OTRS_HOME}"/bin/otrs.SetPermissions.pl "${EROOT%/}${OTRS_HOME}" \ |
165 |
+ --otrs-user=otrs \ |
166 |
+ --web-group=apache \ |
167 |
+ || die "Could not set permissions" |
168 |
+ |
169 |
+ einfo "Installation done!" |
170 |
+ elog "1) Rebuild your config now by running the following commands:" |
171 |
+ elog "sudo -u otrs /usr/bin/env perl "${EROOT%/}${OTRS_HOME}"/bin/otrs.Console.pl Maint::Config::Rebuild" |
172 |
+ elog "sudo -u otrs /usr/bin/env perl "${EROOT%/}${OTRS_HOME}"/bin/otrs.Console.pl Maint::Cache::Delete" |
173 |
+ elog "" |
174 |
+ elog "2) Enable cronjobs with the following command:" |
175 |
+ elog "crontab -u otrs crontab" |
176 |
+ elog "" |
177 |
+ elog "3) systemd users: enable and start OTRS daemon:" |
178 |
+ elog "systemctl enable otrs" |
179 |
+ elog "systemctl start otrs" |
180 |
+} |