1 |
commit: bbd2c392d046d8c44fef63ea527825df37886f5c |
2 |
Author: Samuel Bernardo <samuelbernardo.mail <AT> gmail <DOT> com> |
3 |
AuthorDate: Thu Apr 11 00:36:34 2019 +0000 |
4 |
Commit: Samuel Bernardo <samuelbernardo.mail <AT> gmail <DOT> com> |
5 |
CommitDate: Thu Apr 11 00:36:34 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/user/ssnb.git/commit/?id=bbd2c392 |
7 |
|
8 |
Run python2.7 with scons, since script is done for legacy python version |
9 |
|
10 |
Signed-off-by: Samuel Bernardo <samuelbernardo.mail <AT> gmail.com> |
11 |
|
12 |
app-emulation/opennebula/Manifest | 2 + |
13 |
app-emulation/opennebula/opennebula-5.8.1.ebuild | 187 +++++++++++++++++++++++ |
14 |
2 files changed, 189 insertions(+) |
15 |
|
16 |
diff --git a/app-emulation/opennebula/Manifest b/app-emulation/opennebula/Manifest |
17 |
index 9c675dd..a0b766f 100644 |
18 |
--- a/app-emulation/opennebula/Manifest |
19 |
+++ b/app-emulation/opennebula/Manifest |
20 |
@@ -25,6 +25,7 @@ DIST opennebula-5.4.13.tar.gz 14579822 BLAKE2B 66c6267a6b4ef5754f1f782245ef0708a |
21 |
DIST opennebula-5.4.6.tar.gz 14537181 BLAKE2B 7240dbd209e7aec7c7ccecb95420b1b07761dcf0f1fa5f348101193e42a7af03def090d9ec6a60d32632e4ea31a5dfd03f7ee534a0e96b9e17255d8215f06f49 SHA512 440db6e15499740622c4a25cb8e28f2b718b6d2dfcb7d181f0fab927c03bc8d0ceb241bf08e03f068d73fc795ebe831b4102bebffb37f6aa320713bea66ef3ba |
22 |
DIST opennebula-5.6.0.tar.gz 26357668 BLAKE2B 0bf79201bdac6dc2380507bd7981520948daaa9db7f5e42164c40aecc283b858bc7dc9a8072ebbf4b8632b1746010d2483547bcd343a98718373c774c45ddbb0 SHA512 157e96f8551c5bbc89490373e167638f3a416c0abacfecfe42dc9ef4d88659512be4f03e34a285dff37ea37eab45937a9a58eda9cdf2123161ca22a88f6defe2 |
23 |
DIST opennebula-5.6.1.tar.gz 26297534 BLAKE2B 1216502af4c5e0385e111d79f522cded875f8435de45d16280395bdef2ee638a664793426ecb71152ebace178fccfe50496708fb9f1a85870402030036e06500 SHA512 4978b227fd2bf19a8e56e17bb01defdff6a07f426f361befc4b7e5f0381fd5e255c29915fbf5465fdb0eccdaca3d7ec86a8f57c7629832899dfd671210cfff46 |
24 |
+DIST opennebula-5.8.1.tar.gz 26987763 BLAKE2B 7664bb04e024015a7004a46bdf1975217ad020f9a95922f1c4dc18e3a182b5ddc6ff1071778f428fbd48bd24fd2f6aeb91299188bb70c1a8984b30cbda671109 SHA512 1429b5456711162858134f0daba20373c28b64261f2e9b773e0bc9109f07ac8303a7ee0eed3d9df8646214f966ab5fa2e501e77bd9d4959e45a79c503156d8b3 |
25 |
EBUILD opennebula-4.14.2.ebuild 5992 BLAKE2B d9858fe197615ac54b61ca1637acec8bd991f7b975f95d75bb45161db6953148faa300557109213ba7f0844d9cb0c7774b5900b2c9a5afb3021edbb7412b73eb SHA512 cc18db5d7480f2067d95deb6a61df6c0a40a11ab9e4f6e2491fccdac34f349d527b6ffeedb2d2d2f04c3dba210c2a1316c635b4f69064a69bfd378ea0c4f9ebe |
26 |
EBUILD opennebula-5.4.1.ebuild 5394 BLAKE2B be801a88a64fb6c2345845bdb389a41b7f29664a8421639977058ea6e6b419fda65db70328fbf74782859e52979e52807bd77c1e3ce71a64d456e2b8e831d12b SHA512 a4fd17509e5363838e699abbb609c9ff33de519949aa61121ffc7551405e3204dd7e6f2e0c764fc80c4a8d3f7b68693fe92ffd54c47f36095d949758b653e1dd |
27 |
EBUILD opennebula-5.4.13.ebuild 5394 BLAKE2B 9298d0c8dd1deb510b5de5e74fac171da4a706f4346c0178425340d6d5c2bbcc4eed45d461ba0f5fa4db88abab73f6cad97472ef26f5d0523689444703281bfd SHA512 bbe4e1977788043a79270b1b3d1a9b5478df4781b7fbe75bc6df6f03d1427d5bcf6840bc34ccb18233c2aaf4234c9bd6648f020910baaa68582ca68f712becef |
28 |
@@ -32,4 +33,5 @@ EBUILD opennebula-5.4.15.ebuild 7414 BLAKE2B 75dcddeebbef2092d80d087a7e6186599a2 |
29 |
EBUILD opennebula-5.4.6.ebuild 5394 BLAKE2B be801a88a64fb6c2345845bdb389a41b7f29664a8421639977058ea6e6b419fda65db70328fbf74782859e52979e52807bd77c1e3ce71a64d456e2b8e831d12b SHA512 a4fd17509e5363838e699abbb609c9ff33de519949aa61121ffc7551405e3204dd7e6f2e0c764fc80c4a8d3f7b68693fe92ffd54c47f36095d949758b653e1dd |
30 |
EBUILD opennebula-5.6.0.ebuild 5394 BLAKE2B 9298d0c8dd1deb510b5de5e74fac171da4a706f4346c0178425340d6d5c2bbcc4eed45d461ba0f5fa4db88abab73f6cad97472ef26f5d0523689444703281bfd SHA512 bbe4e1977788043a79270b1b3d1a9b5478df4781b7fbe75bc6df6f03d1427d5bcf6840bc34ccb18233c2aaf4234c9bd6648f020910baaa68582ca68f712becef |
31 |
EBUILD opennebula-5.6.1.ebuild 5394 BLAKE2B 9298d0c8dd1deb510b5de5e74fac171da4a706f4346c0178425340d6d5c2bbcc4eed45d461ba0f5fa4db88abab73f6cad97472ef26f5d0523689444703281bfd SHA512 bbe4e1977788043a79270b1b3d1a9b5478df4781b7fbe75bc6df6f03d1427d5bcf6840bc34ccb18233c2aaf4234c9bd6648f020910baaa68582ca68f712becef |
32 |
+EBUILD opennebula-5.8.1.ebuild 5419 BLAKE2B 4c38582d41d7bc352966bbeb3dbe42eb83aeac3c6589ecb4f68a87ea08f9855aea062b6e14012bbd17f6b18ad67e31f3d5da86bf23d0cbb44280d34496045da0 SHA512 a3506dc7d4f6d37136ef55da86d340fe477749a10c1a07b4b2c86692b5f06646f72cfbbdb4d57a55f841c0a0ecf7eef125fc22ed16ccfaae84c4adbe9b0b6b6b |
33 |
MISC metadata.xml 471 BLAKE2B fecada7f873a86295bd66aa16126682170731bb4cd87dc2cfc7f46503d1d10880cc92f87c388dc6b2d3e8a4d4cba73c4b88a97ce8d23c2254b0d91cb3f820779 SHA512 0be6058785693cef097e2b3ffcffbc7b0011719afcaaf4d10116f490dc23291bdbb9e91f42977c82ef002967a4cbd56f1bebe1f1e61a053a659250a54d7d67d1 |
34 |
|
35 |
diff --git a/app-emulation/opennebula/opennebula-5.8.1.ebuild b/app-emulation/opennebula/opennebula-5.8.1.ebuild |
36 |
new file mode 100644 |
37 |
index 0000000..2fedfad |
38 |
--- /dev/null |
39 |
+++ b/app-emulation/opennebula/opennebula-5.8.1.ebuild |
40 |
@@ -0,0 +1,187 @@ |
41 |
+# Copyright 1999-2016 Gentoo Foundation |
42 |
+# Distributed under the terms of the GNU General Public License v2 |
43 |
+# $Header: $ |
44 |
+ |
45 |
+EAPI=6 |
46 |
+USE_RUBY="ruby24 ruby25 ruby26" |
47 |
+ |
48 |
+inherit user eutils multilib ruby-ng systemd |
49 |
+ |
50 |
+MY_P="opennebula-${PV/_/-}" |
51 |
+ |
52 |
+DESCRIPTION="OpenNebula Virtual Infrastructure Engine" |
53 |
+HOMEPAGE="http://www.opennebula.org/" |
54 |
+SRC_URI="http://downloads.opennebula.org/packages/${PN}-${PV}/${PN}-${PV}.tar.gz" |
55 |
+ |
56 |
+LICENSE="Apache-2.0" |
57 |
+SLOT="0" |
58 |
+KEYWORDS="~amd64" |
59 |
+IUSE="qemu +mysql xen sqlite +extras systemd" |
60 |
+ |
61 |
+RDEPEND=">=dev-libs/xmlrpc-c-1.18.02[abyss,cxx,threads] |
62 |
+ dev-lang/ruby |
63 |
+ extras? ( dev-libs/openssl |
64 |
+ dev-ruby/libxml |
65 |
+ net-misc/curl |
66 |
+ dev-libs/libxslt |
67 |
+ dev-libs/expat |
68 |
+ dev-ruby/uuidtools |
69 |
+ dev-ruby/amazon-ec2 |
70 |
+ dev-ruby/webmock |
71 |
+ dev-ruby/mysql |
72 |
+ dev-ruby/mysql2 |
73 |
+ dev-ruby/parse-cron |
74 |
+ dev-ruby/sequel |
75 |
+ dev-ruby/treetop |
76 |
+ dev-ruby/xml-simple |
77 |
+ dev-ruby/zendesk_api |
78 |
+ dev-libs/log4cpp ) |
79 |
+ mysql? ( virtual/mysql ) |
80 |
+ dev-db/sqlite |
81 |
+ net-misc/openssh |
82 |
+ || ( app-cdr/cdrkit app-cdr/cdrtools ) |
83 |
+ sqlite? ( dev-ruby/sqlite3 ) |
84 |
+ qemu? ( app-emulation/libvirt[libvirtd,qemu] ) |
85 |
+ xen? ( app-emulation/xen-tools )" |
86 |
+DEPEND="${RDEPEND} |
87 |
+ >=dev-util/scons-1.2.0-r1 |
88 |
+ dev-ruby/nokogiri" |
89 |
+ |
90 |
+# make sure no eclass is running tests |
91 |
+RESTRICT="test" |
92 |
+ |
93 |
+S="${WORKDIR}/${PN}-${PV}" |
94 |
+ |
95 |
+ONEUSER="oneadmin" |
96 |
+ONEGROUP="oneadmin" |
97 |
+ |
98 |
+pkg_setup () { |
99 |
+ enewgroup ${ONEGROUP} |
100 |
+ enewuser ${ONEUSER} -1 /bin/bash /var/lib/one ${ONEGROUP} |
101 |
+} |
102 |
+ |
103 |
+src_unpack() { |
104 |
+ default |
105 |
+} |
106 |
+ |
107 |
+src_prepare() { |
108 |
+ sed -i -e 's|chmod|true|' install.sh || die "sed failed" |
109 |
+ eapply_user |
110 |
+} |
111 |
+ |
112 |
+src_configure() { |
113 |
+ : |
114 |
+} |
115 |
+ |
116 |
+src_compile() { |
117 |
+ |
118 |
+ local myconf |
119 |
+ use extras && myconf+="new_xmlrpc=yes " |
120 |
+ use mysql && myconf+="mysql=yes " || myconf+="mysql=no " |
121 |
+ python2.7 $(which scons) \ |
122 |
+ ${myconf} \ |
123 |
+ $(sed -r 's/.*(-j\s*|--jobs=)([0-9]+).*/-j\2/' <<< ${MAKEOPTS}) \ |
124 |
+ || die "building ${PN} failed" |
125 |
+} |
126 |
+ |
127 |
+src_install() { |
128 |
+ DESTDIR=${T} ./install.sh -u ${ONEUSER} -g ${ONEGROUP} || die "install failed" |
129 |
+ |
130 |
+ cd "${T}" |
131 |
+ |
132 |
+ # installing things for real |
133 |
+ dobin bin/* |
134 |
+ |
135 |
+ keepdir /var/{lib,run}/${PN} || die "keepdir failed" |
136 |
+ |
137 |
+ dodir /usr/$(get_libdir)/one |
138 |
+ dodir /var/lock/one |
139 |
+ dodir /var/log/one |
140 |
+ dodir /var/lib/one |
141 |
+ dodir /var/run/one |
142 |
+ dodir /var/tmp/one |
143 |
+ # we have to preserve the executable bits |
144 |
+ cp -a lib/* "${D}/usr/$(get_libdir)/one/" || die "copying lib files failed" |
145 |
+ |
146 |
+ insinto /usr/share/doc/${PF} |
147 |
+ doins -r share/examples |
148 |
+ |
149 |
+ dodir /var/lib/one |
150 |
+ dodir /var/lib/one/vms |
151 |
+ dodir /usr/share/one |
152 |
+ dodir /etc/tmpfiles.d |
153 |
+ # we have to preserve the executable bits |
154 |
+ cp -a var/remotes "${D}/var/lib/one/" || die "copying remotes failed" |
155 |
+ cp -a share/* "${D}/usr/share/one/" || die "copying share failed" |
156 |
+ |
157 |
+ doenvd "${FILESDIR}/99one" |
158 |
+ |
159 |
+ newinitd "${FILESDIR}/opennebula.initd" opennebula |
160 |
+ newinitd "${FILESDIR}/sunstone-server.initd" sunstone-server |
161 |
+ newinitd "${FILESDIR}/oneflow-server.initd" oneflow-server |
162 |
+ newconfd "${FILESDIR}/opennebula.confd" opennebula |
163 |
+ newconfd "${FILESDIR}/sunstone-server.confd" sunstone-server |
164 |
+ newconfd "${FILESDIR}/oneflow-server.confd" oneflow-server |
165 |
+ |
166 |
+ use systemd && systemd_dounit "${FILESDIR}"/opennebula{,-sunstone,-econe,-oneflow,-onegate}.service |
167 |
+ |
168 |
+ insinto /etc/one |
169 |
+ insopts -m 0640 |
170 |
+ doins -r etc/* |
171 |
+ doins "${FILESDIR}/one_auth" |
172 |
+ |
173 |
+ insinto /etc/tmpfiles.d |
174 |
+ doins "${FILESDIR}/tmpfilesd.opennebula.conf" |
175 |
+ |
176 |
+} |
177 |
+ |
178 |
+pkg_postinst() { |
179 |
+ |
180 |
+ |
181 |
+ chown -R oneadmin:oneadmin ${ROOT}var/{lock,lib,log,run,tmp}/one |
182 |
+ chown -R oneadmin:oneadmin ${ROOT}usr/share/one |
183 |
+ chown -R oneadmin:oneadmin ${ROOT}etc/one |
184 |
+ chown -R oneadmin:oneadmin ${ROOT}usr/lib/one |
185 |
+ |
186 |
+ local onedir="${EROOT}var/lib/one" |
187 |
+ if [ ! -d "${onedir}/.ssh" ] ; then |
188 |
+ einfo "Generating ssh-key..." |
189 |
+ umask 0027 || die "setting umask failed" |
190 |
+ mkdir "${onedir}/.ssh" || die "creating ssh directory failed" |
191 |
+ ssh-keygen -q -t dsa -N "" -f "${onedir}/.ssh/id_dsa" || die "ssh-keygen failed" |
192 |
+ cat > "${onedir}/.ssh/config" <<EOF |
193 |
+UserKnownHostsFile /dev/null |
194 |
+Host * |
195 |
+ StrictHostKeyChecking no |
196 |
+EOF |
197 |
+ cat "${onedir}/.ssh/id_dsa.pub" >> "${onedir}/.ssh/authorized_keys" || die "adding key failed" |
198 |
+ chown -R ${ONEUSER}:${ONEGROUP} "${onedir}/.ssh" || die "changing owner failed" |
199 |
+ fi |
200 |
+ |
201 |
+ if use qemu ; then |
202 |
+ elog "Make sure that the user ${ONEUSER} has access to the libvirt control socket" |
203 |
+ elog " /var/run/libvirt/libvirt-sock" |
204 |
+ elog "You can easily check this by executing the following command as ${ONEUSER} user" |
205 |
+ elog " virsh -c qemu:///system nodeinfo" |
206 |
+ elog "If not using using policykit in libvirt, the file you should take a look at is:" |
207 |
+ elog " /etc/libvirt/libvirtd.conf (look for the unix_sock_*_perms parameters)" |
208 |
+ elog "Failure to do so may lead to nodes hanging in PENDING state forever without further notice." |
209 |
+ echo "" |
210 |
+ elog "Should a node hang in PENDING state even with correct permissions, try the following to get more information." |
211 |
+ elog "In /tmp/one-im execute the following command for the biggest one_im-* file:" |
212 |
+ elog " ruby -wd one_im-???" |
213 |
+ echo "" |
214 |
+ elog "OpenNebula doesn't allow you to specify the disc format." |
215 |
+ elog "Unfortunately the default in libvirt is not to guess and" |
216 |
+ elog "it therefores assumes a 'raw' format when using qemu/kvm." |
217 |
+ elog "Set 'allow_disk_format_probing = 0' in /etc/libvirt/qemu.conf" |
218 |
+ elog "to work around this until OpenNebula fixes it." |
219 |
+ fi |
220 |
+ |
221 |
+ elog "If you wish to use the sunstone server, please issue the command" |
222 |
+ #elog "/usr/share/one/install_gems as oneadmin user" |
223 |
+ elog "gem install sequel thin json rack sinatra builder treetop zendesk_api mysql parse-cron" |
224 |
+ |
225 |
+ |
226 |
+} |
227 |
+ |