Apache CloudStack for Arch Linux
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

580 lines
19 KiB

2 years ago
  1. # Maintainer: Pekka Helenius <pekka dot helenius at fjordtek dot com>
  2. # Skip Maven tests?
  3. skip_tests=true
  4. # Install non-OSS (open source software) Java plugins?
  5. # Adds up to 1.5GB to the installation size
  6. install_non_oss=true
  7. maven_options=(
  8. # CloudStack profile options
  9. -P systemvm
  10. #-P eclipse
  11. #-P developer
  12. #-P impatient
  13. #-P vmware
  14. #-P quality
  15. #-P disablecheckstyle
  16. #-P enablefindbugs
  17. -Dorg.slf4j.simpleLogger.defaultLogLevel=warn
  18. )
  19. pythonver=3.7
  20. pkgbase=cloudstack
  21. pkgname=(
  22. 'cloudstack-agent'
  23. 'cloudstack-management'
  24. 'cloudstack-ui'
  25. 'cloudstack-common'
  26. 'cloudstack-cli'
  27. 'cloudstack-usage'
  28. 'cloudstack-mysql-ha'
  29. # 'cloudstack-baremetal-agent'
  30. # 'cloudstack-marvin'
  31. # 'cloudstack-integration-tests'
  32. # 'cloudstack-docs'
  33. )
  34. _commit=44c08b5acc598972b4f0af576ffdea4e2447cb41 # 4.16.0.0
  35. pkgver=4.16.0.0.r0.g44c08b5acc
  36. pkgrel=1
  37. groups=(cloudstack)
  38. pkgdesc='Open Source Cloud Computing'
  39. arch=('any')
  40. url='https://cloudstack.apache.org/'
  41. license=('Apache2')
  42. depends=(
  43. 'systemd'
  44. 'logrotate'
  45. 'libvirt'
  46. 'jre11-openjdk'
  47. 'java-runtime-common'
  48. 'mysql'
  49. 'python'
  50. 'python-setuptools'
  51. 'python-mysql-connector'
  52. # Both iptables & ebtables executables is required by cloudstack-agent
  53. 'iptables-nft'
  54. 'ipmitool'
  55. 'nfs-utils'
  56. 'openssh'
  57. )
  58. makedepends=(
  59. # CloudStack source retrieval
  60. 'git'
  61. 'wget'
  62. # CloudStack compilation
  63. 'jdk11-openjdk'
  64. 'maven'
  65. # CloudStack UI compilation
  66. # <16 required by cloudstack-ui npm compilation process due to implementation issues
  67. # See: https://github.com/sass/node-sass/issues/3077
  68. 'nodejs<16'
  69. 'npm'
  70. 'gcc'
  71. # # CloudStack apidocs compilation
  72. # 'python'
  73. )
  74. optdepends=(
  75. 'qemu: A generic and open source machine emulator and virtualizer'
  76. 'cloudmonkey: Command line interface for Apache CloudStack management'
  77. 'python-solidfire-sdk: SolidFire Python SDK for application integration'
  78. 'edk2-ovmf: Firmware for Virtual Machines (x86_64, i686)'
  79. 'openvswitch: Production Quality, Multilayer Open Virtual Switch'
  80. 'nfs-utils: Support programs for Network File Systems'
  81. )
  82. source=(
  83. "${pkgbase}::git+https://github.com/apache/${pkgbase}.git#commit=${_commit}"
  84. "cloudstack.sysuser.conf"
  85. "cloudstack.mysql.conf"
  86. "uefi.properties"
  87. "cloudstack-nfs.exports"
  88. "patch_domr-path.patch"
  89. "patch_python3.patch"
  90. "cloudbr0.netdev"
  91. "cloudbr0.network"
  92. "cloudbr1.netdev"
  93. "cloudbr1.network"
  94. "cloudbr2.netdev"
  95. "cloudbr2.network"
  96. )
  97. if [[ ${skip_tests} == "true" ]]; then
  98. maven_options+=(-DskipTests)
  99. fi
  100. if [[ ${install_non_oss} == "true" ]]; then
  101. source+=(
  102. "${pkgbase}-nonoss::git+https://github.com/shapeblue/${pkgbase}-nonoss.git"
  103. )
  104. maven_options+=(-Dnoredist)
  105. fi
  106. # options=(!emptydirs)
  107. sha256sums=('SKIP'
  108. '1ad0d6b9a15889763bea92c71ecf9dc44e11e408260cdc54efa4d7acd849230f'
  109. '69b315a10f88c24d6fe2b248b0593691d656f8992e6e37f8b0a4d2d4a9caca40'
  110. '2ac98910f320785ebbc682a426f4eef6d8b4ca5c8c55195dc4c048072fa93fb6'
  111. '099a4e36ced56cebb8e0d4c058582bc549a1b75b87f889bbd3bb7f83c17134db'
  112. '8691b6b47164d11d3c1eff90a0108e694427463fb3d49608628a5d0121b6a5d4'
  113. '2515da6f9195c7e3bce321bd328743ee4c685ccd01ddb4099202637036eab40e'
  114. '4d5d5c4d923ceec434403fc416a4d09a820fdb49ece6e4f6d0b32a05014446be'
  115. 'e3be7fda05b639c1b82db854347262f8206639f78f13d5f207b52c9f6a126a8d'
  116. 'dfc16a17e57b9d174aae8abee6c04b8a6b02ffc96909315f302199e43dea9b9e'
  117. '2fa8cf39924356c5af6403f09ac17930b6d4f38c509cd655f36f705d1dc9d280'
  118. '1bd92d5f69a49c03a492e96f03efdebcef88a73948410511b715339735e15d3f'
  119. '0ce7c6173c80fa74de5a473336ab099337e9248cceef3b7b33c7199baf71aa33'
  120. 'SKIP')
  121. pkgver() {
  122. cd ${pkgbase}
  123. git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
  124. }
  125. prepare() {
  126. if [[ ${install_non_oss} == "true" ]]; then
  127. msg2 "Installing non-OSS CloudStack plugins ($HOME/.m2)"
  128. cd ${pkgbase}-nonoss
  129. ./install-non-oss.sh
  130. fi
  131. cd ${srcdir}/${pkgbase}
  132. patch -Np1 -i ../patch_domr-path.patch
  133. patch -Np1 -i ../patch_python3.patch
  134. rm build/replace.properties
  135. # Compile-time variables
  136. echo "
  137. AGENTCLASSPATH=
  138. AGENTLOGDIR=/var/log/cloudstack/agent
  139. AGENTLOG=/var/log/cloudstack/agent/agent.log
  140. AGENTSYSCONFDIR=/etc/cloudstack/agent
  141. APISERVERLOG=/var/log/cloudstack/management/apilog.log
  142. BINDIR=/usr/bin
  143. COMMONLIBDIR=/usr/share/cloudstack-common
  144. COMPONENTS-SPEC=components-premium.xml
  145. CONFIGUREVARS=
  146. DBDRIVER=jdbc:mysql
  147. DBHOST=localhost
  148. DBPW=cloud
  149. DBROOTPW=
  150. DBUSER=cloud
  151. DEPSCLASSPATH=
  152. DOCDIR=
  153. IPALOCATORLOG=/var/log/cloudstack/management/ipallocator.log
  154. JAVADIR=/usr/share/java
  155. LIBEXECDIR=/usr/libexec
  156. LOCKDIR=/var/lock
  157. MSCLASSPATH=
  158. MSCONF=/etc/cloudstack/management
  159. MSLOGDIR=/var/log/cloudstack/management
  160. MSLOG=/var/log/cloudstack/management/management-server.log
  161. MSMNTDIR=/var/cloudstack/mnt
  162. MSUSER=cloud
  163. PACKAGE=cloudstack
  164. PIDDIR=/run
  165. PLUGINJAVADIR=/usr/share/cloudstack-management/plugin
  166. PREMIUMJAVADIR=/usr/share/cloudstack-management/premium
  167. PYTHONDIR=/usr/lib/python${pythonver}/site-packages/
  168. REMOTEHOST=localhost
  169. SERVERSYSCONFDIR=/etc/cloudstack/server
  170. SETUPDATADIR=/usr/share/cloudstack-management/setup
  171. SYSCONFDIR=/etc
  172. SYSTEMCLASSPATH=
  173. SYSTEMJARS=
  174. USAGECLASSPATH=
  175. USAGELOG=/var/log/cloudstack/usage/usage.log
  176. USAGESYSCONFDIR=/etc/cloudstack/usage
  177. VERSION=$(printf "%s" $(git describe --long --tags | cut -d- -f1))
  178. " > build/replace.properties
  179. }
  180. build() {
  181. cd ${pkgbase}
  182. export JAVA_HOME=/usr/lib/jvm/java-11-openjdk/
  183. export PATH=$JAVA_HOME/bin:$PATH
  184. mvn clean install ${maven_options[*]}
  185. # CloudStack UI
  186. cd ui && npm install && npm run build && cd ..
  187. }
  188. package_cloudstack-agent() {
  189. depends=('python' 'jre11-openjdk' 'logrotate' 'openssh' 'systemd' 'iptables-nft')
  190. pkgdesc='Apache CloudStack Agent'
  191. backup=(
  192. etc/cloudstack/agent/agent.properties
  193. etc/cloudstack/agent/uefi.properties
  194. )
  195. install=cloudstack-agent.install
  196. cd ${pkgbase}
  197. mkdir -p ${pkgdir}/etc/{cloudstack/agent,default,profile.d}
  198. mkdir -p ${pkgdir}/var/{cache/cloudstack,log/cloudstack}
  199. # TODO: Missing doc files: INSTALL.md.gz, LICENSE.gz, NOTICE.gz, changelog.gz, copyright
  200. mkdir -p ${pkgdir}/usr/{bin,share/cloudstack-agent} #,share/doc/cloudstack-agent}
  201. mkdir -p ${pkgdir}/usr/share/cloudstack-agent/{plugins,lib,scripts}
  202. install -Dm0644 plugins/hypervisors/kvm/target/cloud-plugin-hypervisor-kvm*.jar ${pkgdir}/usr/share/cloudstack-agent/lib/
  203. install -D plugins/hypervisors/kvm/target/dependencies/* ${pkgdir}/usr/share/cloudstack-agent/lib/
  204. mkdir -p ${pkgdir}/usr/lib/systemd/system
  205. install -Dm0644 packaging/systemd/cloudstack-agent.service ${pkgdir}/usr/lib/systemd/system/
  206. install -Dm0644 packaging/systemd/cloudstack-agent.default ${pkgdir}/etc/default/cloudstack-agent
  207. install -Dm0644 packaging/systemd/cloudstack-rolling-maintenance@.service ${pkgdir}/usr/lib/systemd/system/
  208. install -Dm0644 agent/target/transformed/cloudstack-agent.logrotate ${pkgdir}/etc/logrotate.d/cloudstack-agent
  209. install -Dm0755 agent/target/transformed/cloud-setup-agent ${pkgdir}/usr/bin/cloudstack-setup-agent
  210. install -Dm0755 agent/target/transformed/cloud-ssh ${pkgdir}/usr/bin/cloudstack-ssh
  211. install -Dm0755 agent/target/transformed/cloudstack-agent-profile.sh ${pkgdir}/etc/profile.d/cloudstack-agent-profile.sh
  212. install -Dm0755 agent/target/transformed/cloudstack-agent-upgrade ${pkgdir}/usr/bin/
  213. install -Dm0755 agent/target/transformed/cloud-guest-tool ${pkgdir}/usr/bin/cloudstack-guest-tool
  214. install -Dm0644 agent/target/transformed/libvirtqemuhook ${pkgdir}/usr/share/cloudstack-agent/lib/
  215. install -Dm0644 agent/target/transformed/rolling-maintenance ${pkgdir}/usr/share/cloudstack-agent/lib/
  216. install -D agent/target/transformed/environment.properties ${pkgdir}/etc/cloudstack/agent/
  217. install -D agent/target/transformed/agent.properties ${pkgdir}/etc/cloudstack/agent/
  218. install -D agent/target/transformed/log4j-cloud.xml ${pkgdir}/etc/cloudstack/agent/
  219. # Fix: Add missing uefi.properties file
  220. install -Dm0644 ${srcdir}/uefi.properties ${pkgdir}/etc/cloudstack/agent/
  221. # Fix: Add missing log path
  222. mkdir -p ${pkgdir}/var/log/cloudstack/agent
  223. # Fix: Install missing script files
  224. # TODO: Some script files have referrals to unknown 'cmdline' file.
  225. cp -r systemvm/agent/scripts/* ${pkgdir}/usr/share/cloudstack-agent/scripts/
  226. chmod 0755 ${pkgdir}/usr/share/cloudstack-agent/scripts/*.sh
  227. for i in $(find ${pkgdir}/usr/share/cloudstack-agent/scripts/ -iname "*.sh"); do
  228. sed -i 's/\/cloud\//\/cloudstack\//g' "${i}"
  229. sed -i 's/\/usr\/local\//\/usr\//g' "${i}"
  230. done
  231. # Fix: Add & correct missing paths
  232. echo "
  233. # Full path: paths.script + value here
  234. # See environment.properties
  235. hypervisor.scripts.dir=scripts/vm/hypervisor
  236. kvm.scripts.dir=scripts/vm/hypervisor/kvm
  237. network.scripts.dir=scripts/vm/network/vnet
  238. storage.scripts.dir=scripts/storage/qcow2
  239. public.network.device=cloudbr0
  240. private.network.device=cloudbr1
  241. guest.network.device=cloudbr2
  242. #ipv6disabled=true
  243. host.cache.location=/var/cache/cloudstack
  244. # BridgeVifDriver or DirectVifDriver
  245. libvirt.vif.driver=com.cloud.hypervisor.kvm.resource.BridgeVifDriver
  246. " >> ${pkgdir}/etc/cloudstack/agent/agent.properties
  247. }
  248. package_cloudstack-management() {
  249. depends=('python' 'jre11-openjdk' 'mysql' 'systemd' 'ipmitool' 'nfs-utils' 'openssh')
  250. pkgdesc='Management for Apache CloudStack'
  251. install=cloudstack-management.install
  252. noextract=(
  253. systemvmtemplate-4.16.0-kvm.qcow2.bz2
  254. systemvmtemplate-4.16.0-xen.vhd.bz2
  255. )
  256. backup=(
  257. etc/cloudstack/management/server.properties
  258. etc/cloudstack/management/db.properties
  259. etc/cloudstack/management/environment.properties
  260. )
  261. cd ${pkgbase}
  262. mkdir -p ${pkgdir}/etc/cloudstack/management
  263. mkdir -p ${pkgdir}/etc/security/limits.d/
  264. mkdir -p ${pkgdir}/etc/sudoers.d/
  265. chmod 0750 ${pkgdir}/etc/sudoers.d/
  266. mkdir -p ${pkgdir}/usr/share/cloudstack-management/{lib,setup,templates/systemvm,plugin,premium,webapp}
  267. mkdir -p ${pkgdir}/var/cache/cloudstack/management
  268. mkdir -p ${pkgdir}/var/log/cloudstack/{management,ipallocator}
  269. mkdir -p ${pkgdir}/var/lib/cloudstack/{management,mnt}
  270. # Fix: Allocate paths for NFS exports
  271. mkdir -p ${pkgdir}/var/lib/cloudstack/data/storage/{primary,secondary}
  272. cp -r client/target/utilities/scripts/db/* ${pkgdir}/usr/share/cloudstack-management/setup/
  273. cp -r ui/dist/* ${pkgdir}/usr/share/cloudstack-management/webapp/
  274. cp -r client/target/classes/META-INF/webapp/WEB-INF ${pkgdir}/usr/share/cloudstack-management/webapp/
  275. for i in \
  276. cloud-migrate-databases \
  277. cloud-setup-databases \
  278. cloud-setup-management \
  279. cloud-setup-encryption \
  280. cloud-sysvmadm \
  281. cloud-update-xenserver-licenses \
  282. cloud-set-guest-password \
  283. cloud-set-guest-sshkey
  284. do
  285. install -D client/target/utilities/bin/${i} ${pkgdir}/usr/bin/$(echo ${i} | sed 's/cloud\-/cloudstack\-/')
  286. done
  287. cp client/target/conf/* ${pkgdir}/etc/cloudstack/management/
  288. cp client/target/cloud-client-ui-*.jar ${pkgdir}/usr/share/cloudstack-management/lib/
  289. for i in $(find ${pkgdir}/usr/share/cloudstack-management/lib/ -iname "cloud-client-ui*"); do
  290. mv "${i}" $(echo "${i}" | sed 's/cloud\-client\-ui/cloudstack/')
  291. done
  292. cp client/target/lib/*jar ${pkgdir}/usr/share/cloudstack-management/lib/
  293. cp -rf engine/schema/dist/systemvm-templates/* ${pkgdir}/usr/share/cloudstack-management/templates/systemvm/
  294. rm -rf ${pkgdir}/usr/share/cloudstack-management/templates/systemvm/md5sum.txt
  295. # Nast hack for a couple of configuration files
  296. cp -f server/target/conf/cloudstack-limits.conf ${pkgdir}/etc/security/limits.d/cloudstack-limits.conf
  297. cp -f server/target/conf/cloudstack-sudoers ${pkgdir}/etc/sudoers.d/cloudstack
  298. # Allow non-root user to add a KVM host
  299. j=$(echo "$(grep Cmnd_Alias ${pkgdir}/etc/sudoers.d/cloudstack), /usr/bin/cloudstack-setup-agent" | sed 's/\//\\\//g')
  300. sed -i -i "s/^Cmnd_Alias.*/$j/" ${pkgdir}/etc/sudoers.d/cloudstack
  301. chmod 0440 ${pkgdir}/etc/sudoers.d/cloudstack
  302. # TODO: This should all be in /etc/cloudstack/management
  303. ln -s /etc/cloudstack/management ${pkgdir}/usr/share/cloudstack-management/conf
  304. ln -s /var/log/cloudstack/management ${pkgdir}/usr/share/cloudstack-management/logs
  305. mkdir -p ${pkgdir}/usr/lib/systemd/system
  306. install -m0644 packaging/systemd/cloudstack-management.service ${pkgdir}/usr/lib/systemd/system/cloudstack-management.service
  307. install -Dm0644 packaging/systemd/cloudstack-management.default ${pkgdir}/etc/default/cloudstack-management
  308. # Fix: Add missing 'cloud' user to the system
  309. mkdir -p ${pkgdir}/usr/lib/sysusers.d
  310. install -Dm0644 ${srcdir}/cloudstack.sysuser.conf ${pkgdir}/usr/lib/sysusers.d/cloudstack.conf
  311. # Fix: Add missing NFS exports file
  312. mkdir -p ${pkgdir}/etc/exports.d
  313. install -Dm0644 ${srcdir}/cloudstack-nfs.exports ${pkgdir}/etc/exports.d/cloudstack.exports
  314. # Fix: Set global database configuration values
  315. mkdir -p ${pkgdir}/etc/mysql/conf.d/
  316. install -Dm0644 ${srcdir}/cloudstack.mysql.conf ${pkgdir}/etc/mysql/conf.d/cloudstack.cf
  317. rm -f ${pkgdir}/usr/share/cloudstack-management/webapp/config.json
  318. ln -s /etc/cloudstack/ui/config.json ${pkgdir}/usr/share/cloudstack-management/webapp/config.json
  319. # Fix: Symlink log4j.xml
  320. ln -s /etc/cloudstack/management/log4j-cloud.xml ${pkgdir}/etc/cloudstack/management/log4j.xml
  321. }
  322. package_cloudstack-ui() {
  323. depends=()
  324. pkgdesc='Apache CloudStack UI'
  325. cd ${pkgbase}
  326. # TODO: Missing doc files: INSTALL.md.gz, LICENSE.gz, NOTICE.gz, changelog.gz, copyright
  327. # mkdir -p ${pkgdir}/usr/share/doc/cloudstack-ui/
  328. mkdir -p ${pkgdir}/etc/cloudstack/ui
  329. mkdir -p ${pkgdir}/usr/share/cloudstack-ui
  330. cp -r ui/dist/config.json ${pkgdir}/etc/cloudstack/ui/
  331. cp -r ui/dist/* ${pkgdir}/usr/share/cloudstack-ui/
  332. rm -f ${pkgdir}/usr/share/cloudstack-ui/config.json
  333. ln -s /etc/cloudstack/ui/config.json ${pkgdir}/usr/share/cloudstack-ui/config.json
  334. }
  335. package_cloudstack-common() {
  336. depends=('python' 'jre11-openjdk')
  337. pkgdesc='Common files for Apache CloudStack'
  338. install=cloudstack-common.install
  339. cd ${pkgbase}
  340. # TODO: Missing doc files: INSTALL.md.gz, LICENSE.gz, NOTICE.gz, changelog.gz, copyright
  341. # mkdir -p ${pkgdir}/usr/share/doc/cloudstack-common/
  342. mkdir -p ${pkgdir}/usr/share/cloudstack-common/{scripts,setup,lib}
  343. for i in installer network storage util vm; do
  344. cp -r scripts/${i} ${pkgdir}/usr/share/cloudstack-common/scripts
  345. done
  346. # Fix: Add missing Cisco network files
  347. cp -r client/target/common/scripts/network/cisco ${pkgdir}/usr/share/cloudstack-common/scripts/network/
  348. # TODO: Missing utils/bindir/cloud-sccs -> usr/bin/cloud-sccs
  349. install -D systemvm/dist/systemvm.iso ${pkgdir}/usr/share/cloudstack-common/vms/systemvm.iso
  350. # We need jasypt for 'cloud-install-sys-tmplt' executable, so this is a nasty hack to get it into the right place
  351. install -D agent/target/dependencies/jasypt-1.9.*.jar ${pkgdir}/usr/share/cloudstack-common/lib
  352. # Fix: Populate network interfaces for CloudStack
  353. mkdir -p ${pkgdir}/usr/lib/systemd/network/
  354. install -Dm0644 ${srcdir}/cloudbr0.netdev ${pkgdir}/usr/lib/systemd/network/
  355. install -Dm0644 ${srcdir}/cloudbr0.network ${pkgdir}/usr/lib/systemd/network/
  356. install -Dm0644 ${srcdir}/cloudbr1.netdev ${pkgdir}/usr/lib/systemd/network/
  357. install -Dm0644 ${srcdir}/cloudbr1.network ${pkgdir}/usr/lib/systemd/network/
  358. }
  359. package_cloudstack-cli() {
  360. depends=('python' 'python-mysql-connector')
  361. pkgdesc='Python bindings for Apache CloudStack (CLI)'
  362. cd ${pkgbase}
  363. mkdir -p ${pkgdir}/usr/lib/python${pythonver}/site-packages/
  364. cp -r python/lib/cloud* ${pkgdir}/usr/lib/python${pythonver}/site-packages/
  365. }
  366. package_cloudstack-usage() {
  367. depends=('jre11-openjdk' 'systemd')
  368. pkgdesc='Usage Server for Apache CloudStack'
  369. backup=(
  370. etc/cloudstack/usage/db.properties
  371. )
  372. cd ${pkgbase}
  373. # TODO: Missing doc files: INSTALL.md.gz, LICENSE.gz, NOTICE.gz, changelog.gz, copyright
  374. # mkdir -p ${pkgdir}/usr/share/doc/cloudstack-usage/
  375. mkdir -p ${pkgdir}/etc/cloudstack/usage
  376. mkdir -p ${pkgdir}/usr/share/cloudstack-usage/{lib,plugins}
  377. mkdir -p ${pkgdir}/var/log/cloudstack/usage
  378. install -Dm0644 usage/target/cloud-usage-*.jar ${pkgdir}/usr/share/cloudstack-usage/
  379. install -D usage/target/dependencies/* ${pkgdir}/usr/share/cloudstack-usage/lib/
  380. cp client/target/lib/mysql*jar ${pkgdir}/usr/share/cloudstack-usage/lib/
  381. cp usage/target/transformed/db.properties ${pkgdir}/etc/cloudstack/usage/
  382. cp usage/target/transformed/log4j-cloud_usage.xml ${pkgdir}/etc/cloudstack/usage/log4j-cloud.xml
  383. mkdir -p ${pkgdir}/usr/lib/systemd/system
  384. install -m0644 packaging/systemd/cloudstack-usage.service ${pkgdir}/usr/lib/systemd/system/cloudstack-usage.service
  385. install -Dm0644 packaging/systemd/cloudstack-usage.default ${pkgdir}/etc/default/cloudstack-usage
  386. }
  387. package_cloudstack-mysql-ha() {
  388. pkgdesc='MySQL High Availability plugin for Apache CloudStack'
  389. depends=('mysql' 'jre11-openjdk')
  390. cd ${pkgbase}
  391. mkdir -p ${pkgdir}/usr/share/cloudstack-mysql-ha/lib
  392. install -Dm0644 plugins/database/mysql-ha/target/cloud-plugin-database-mysqlha-*.jar ${pkgdir}/usr/share/cloudstack-mysql-ha/lib/
  393. }
  394. # TODO: The executable script is not compatible with Arch Linux
  395. #package_cloudstack-baremetal-agent() {
  396. #
  397. # pkgdesc='BareMetal PXE server for Apache CloudStack'
  398. # depends=('python' 'xinetd' 'bash-completion' 'dhcp' 'tftp-hpa' 'iptables')
  399. #
  400. # cd ${pkgbase}
  401. #
  402. # mkdir -p ${pkgdir}/usr/bin
  403. # install -Dm0755 client/target/utilities/bin/cloud-setup-baremetal ${pkgdir}/usr/bin/
  404. #}
  405. # TODO: missing build-time directory
  406. # tools/marvin/marvin/cloudstackAPI
  407. # package_cloudstack-marvin() {
  408. #
  409. # depends=(
  410. # 'python'
  411. # 'python-mysql-connector'
  412. # 'python-urllib3'
  413. # 'python-paramiko'
  414. # 'python-requests'
  415. # 'python-nose'
  416. # 'python-ddt'
  417. # 'python-pyvmomi' #AUR package
  418. # 'python-netaddr'
  419. # 'python-dnspython'
  420. # 'python-pytz'
  421. # 'python-kubernetes'
  422. #
  423. # 'python-ipmisim'
  424. # 'python-pycrypt'
  425. # # TODO: missing Python dependency: 'retries'
  426. # )
  427. #
  428. # makedepends=(
  429. # 'python-setuptools'
  430. # )
  431. #
  432. # pkgdesc='Python client for Apache CloudStack'
  433. #
  434. # cd ${pkgbase}/tools/marvin
  435. #
  436. # # TODO: Should we build this package in build() section?
  437. # python setup.py build
  438. #
  439. # python setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
  440. #
  441. # # TODO: Deprecate this part
  442. # #mkdir -p ${pkgdir}/usr/share/cloudstack-marvin
  443. # #cp tools/marvin/dist/Marvin-*.tar.gz ${pkgdir}/usr/share/cloudstack-marvin/
  444. #
  445. # }
  446. #package_cloudstack-integration-tests() {
  447. # TODO: Missing doc files: INSTALL.md.gz, LICENSE.gz, NOTICE.gz, changelog.gz, copyright
  448. # mkdir -p ${pkgdir}/usr/share/doc/cloudstack-integration-tests/
  449. # pkgdesc='Integration tests for Apache CloudStack'
  450. #
  451. # cd ${pkgbase}
  452. #
  453. # mkdir -p ${pkgdir}/usr/share/cloudstack-integration-tests
  454. # cp -r test/integration/* ${pkgdir}/usr/share/cloudstack-integration-tests/
  455. #
  456. #}
  457. #package_cloudstack-docs() {
  458. # TODO: Missing doc files: INSTALL.md.gz, LICENSE.gz, NOTICE.gz, changelog.gz, copyright
  459. # mkdir -p ${pkgdir}/usr/share/doc/cloudstack-docs/
  460. # pkgdesc='Apache CloudStack docs'
  461. #
  462. # cd ${pkgbase}
  463. #
  464. #}