Merge branch 'master' into feature/cleanup-gitlab
This commit is contained in:
		
						commit
						a1f8cfb8ec
					
				
					 16 changed files with 1113 additions and 5 deletions
				
			
		
							
								
								
									
										4
									
								
								dev-libs/libgit2/Manifest
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								dev-libs/libgit2/Manifest
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,4 @@ | |||
| AUX libgit2-0.24.0_rc1-fix-version.patch 529 SHA256 b1726938ed7ac9dc744bad1c3894816defcf652e080f354f6e90253c1387d754 SHA512 a8db6a63781ce4fdc40f9f9eca193e8b4e8a6cc6a9fb547632f1d53483005cbae06fe35cf96768c0c577a4de1226e06c8a003cee4e1c6e1f3a328dbd7f44798b WHIRLPOOL ce13a604c0a555e05b10269c35b24eba3d0286254fc4c132d244b61479dc1d98f293babe7b3fbf24ee5cc0f6bef33db0ebc238a8e6078bd40e641b2077f8189c | ||||
| DIST libgit2-0.24.0_rc1.tar.gz 4165326 SHA256 e956fb569ddaf2d1d29307b4dc361121160ea7ab052eb3dc1c07b95175cb842d SHA512 c73bee9aaba3a36fca35fa0e3183e5636fa9be2ba98b1b93562f390e5f74b0be817ba73781a13e7ae5f880411465877864ca244ad6ac52ccd89d905d5b103e6c WHIRLPOOL 9d442e2894548462e3bda477bbacf4ac2190e8b9cb8c2b34e443568249b6ab63dd316d267e12fad84acfbfbc0af8aa3674e9c5dd717fa8deac4d07e586f82377 | ||||
| EBUILD libgit2-0.24.0_rc1.ebuild 1838 SHA256 0fcac9187a311ca7086014839c9b87a67288d3b6043a1c7d9e0dbf25bba1149b SHA512 53648baaae16c63c775909eb426e721ac8d1f3059274a1f46eb0f3aa2331e7db3327346964c16d770a1bd6307f204d1136de682e29206d7aed6c5eaa304c1aa7 WHIRLPOOL 0820061b5c98811fa5d61a9fb753dd52983b475b975c2576c44e3a84a0dd298a000c4f13399b7d2c65d011d8f030ef5cde0f1b319263c9e004ffd39f3cd64aba | ||||
| MISC metadata.xml 802 SHA256 446c2a35f3209339e906828d8250d3d784cb3796c4da5740cbd6ebf301d92f4a SHA512 9d2dba83bfd1791e2cf2afd2b939ed66456e4db0723f2789ea3b1227e14b0a7d685d9a7adcaae050b6574e99a9301ff1c484b024dbf8e3dcd44e56a14d84ee99 WHIRLPOOL 268fb7c0d932e4c7b8ce4554c2d04341c77eba94ba25066746b7289111e76446f3c411efc454b3a639aaa98b67c030392c6fab77185f8bc9dac4dce9b4a47e36 | ||||
							
								
								
									
										20
									
								
								dev-libs/libgit2/files/libgit2-0.24.0_rc1-fix-version.patch
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								dev-libs/libgit2/files/libgit2-0.24.0_rc1-fix-version.patch
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,20 @@ | |||
| diff --git a/include/git2/version.h b/include/git2/version.h
 | ||||
| index 6837e90..7572da1 100644
 | ||||
| --- a/include/git2/version.h
 | ||||
| +++ b/include/git2/version.h
 | ||||
| @@ -7,12 +7,12 @@
 | ||||
|  #ifndef INCLUDE_git_version_h__ | ||||
|  #define INCLUDE_git_version_h__ | ||||
|   | ||||
| -#define LIBGIT2_VERSION "0.23.0"
 | ||||
| +#define LIBGIT2_VERSION "0.24.0-rc1"
 | ||||
|  #define LIBGIT2_VER_MAJOR 0 | ||||
| -#define LIBGIT2_VER_MINOR 23
 | ||||
| +#define LIBGIT2_VER_MINOR 24
 | ||||
|  #define LIBGIT2_VER_REVISION 0 | ||||
|  #define LIBGIT2_VER_PATCH 0 | ||||
|   | ||||
| -#define LIBGIT2_SOVERSION 23
 | ||||
| +#define LIBGIT2_SOVERSION 24
 | ||||
|   | ||||
|  #endif | ||||
							
								
								
									
										81
									
								
								dev-libs/libgit2/libgit2-0.24.0_rc1.ebuild
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										81
									
								
								dev-libs/libgit2/libgit2-0.24.0_rc1.ebuild
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,81 @@ | |||
| # Copyright 1999-2016 Gentoo Foundation | ||||
| # Distributed under the terms of the GNU General Public License v2 | ||||
| # $Id$ | ||||
| 
 | ||||
| EAPI=5 | ||||
| 
 | ||||
| inherit cmake-utils multilib | ||||
| 
 | ||||
| MY_PV=${PV/_/-} | ||||
| 
 | ||||
| if [[ ${PV} == "9999" ]] ; then | ||||
| 	EGIT_REPO_URI="https://github.com/${PN}/${PN}.git" | ||||
| 	inherit git-r3 | ||||
| else | ||||
| 	SRC_URI="https://github.com/${PN}/${PN}/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz" | ||||
| 	KEYWORDS="amd64 ~arm ~x86 ~ppc-macos" | ||||
| fi | ||||
| 
 | ||||
| DESCRIPTION="A linkable library for Git" | ||||
| HOMEPAGE="https://libgit2.github.com/" | ||||
| 
 | ||||
| LICENSE="GPL-2-with-linking-exception" | ||||
| SLOT="0/24" | ||||
| IUSE="examples gssapi libressl ssh test threads trace" | ||||
| 
 | ||||
| S="${WORKDIR}/${PN}-${MY_PV}" | ||||
| 
 | ||||
| RDEPEND=" | ||||
| 	!libressl? ( dev-libs/openssl:0 ) | ||||
| 	libressl? ( dev-libs/libressl ) | ||||
| 	sys-libs/zlib | ||||
| 	net-libs/http-parser:= | ||||
| 	gssapi? ( virtual/krb5 ) | ||||
| 	ssh? ( net-libs/libssh2 ) | ||||
| " | ||||
| DEPEND="${RDEPEND} | ||||
| 	virtual/pkgconfig | ||||
| " | ||||
| 
 | ||||
| DOCS=( AUTHORS CONTRIBUTING.md CONVENTIONS.md README.md ) | ||||
| 
 | ||||
| src_prepare() { | ||||
| 	# skip online tests | ||||
| 	sed -i '/libgit2_clar/s/-ionline/-xonline/' CMakeLists.txt || die | ||||
| 
 | ||||
| 	epatch "${FILESDIR}/${P}-fix-version.patch" | ||||
| 	cmake-utils_src_prepare | ||||
| } | ||||
| 
 | ||||
| src_configure() { | ||||
| 	local mycmakeargs=( | ||||
| 		-DLIB_INSTALL_DIR="${EPREFIX}/usr/$(get_libdir)" | ||||
| 		$(cmake-utils_use_build test CLAR) | ||||
| 		$(cmake-utils_use_enable trace TRACE) | ||||
| 		$(cmake-utils_use_use gssapi GSSAPI) | ||||
| 		$(cmake-utils_use_use ssh SSH) | ||||
| 		$(cmake-utils_use threads THREADSAFE) | ||||
| 	) | ||||
| 	cmake-utils_src_configure | ||||
| } | ||||
| 
 | ||||
| src_test() { | ||||
| 	if [[ ${EUID} -eq 0 ]] ; then | ||||
| 		# repo::iterator::fs_preserves_error fails if run as root | ||||
| 		# since root can still access dirs with 0000 perms | ||||
| 		ewarn "Skipping tests: non-root privileges are required for all tests to pass" | ||||
| 	else | ||||
| 		local TEST_VERBOSE=1 | ||||
| 		cmake-utils_src_test | ||||
| 	fi | ||||
| } | ||||
| 
 | ||||
| src_install() { | ||||
| 	cmake-utils_src_install | ||||
| 
 | ||||
| 	if use examples ; then | ||||
| 		egit_clean examples | ||||
| 		dodoc -r examples | ||||
| 		docompress -x /usr/share/doc/${PF}/examples | ||||
| 	fi | ||||
| } | ||||
							
								
								
									
										21
									
								
								dev-libs/libgit2/metadata.xml
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								dev-libs/libgit2/metadata.xml
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,21 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | ||||
| <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> | ||||
| <pkgmetadata> | ||||
| 	<maintainer type="person"> | ||||
| 		<email>manuel@fritteli.ch</email> | ||||
| 		<name>Manuel Friedli</name> | ||||
| 	</maintainer> | ||||
| 	<longdescription lang="en"> | ||||
| 		libgit2 is a portable, pure C implementation of the Git core methods provided | ||||
| 		as a re-entrant linkable library with a solid API, allowing you to write native | ||||
| 		speed custom Git applications in any language which supports C bindings. | ||||
| 	</longdescription> | ||||
| 	<use> | ||||
| 		<flag name="gssapi">Enable GSSAPI support for SPNEGO auth</flag> | ||||
| 		<flag name="ssh">Enable SSH transport support</flag> | ||||
| 		<flag name="trace">Enable tracing support</flag> | ||||
| 	</use> | ||||
| 	<upstream> | ||||
| 		<remote-id type="github">libgit2/libgit2</remote-id> | ||||
| 	</upstream> | ||||
| </pkgmetadata> | ||||
|  | @ -3,5 +3,9 @@ AUX gitlab-ci-multi-runner.init 696 SHA256 03fc8cf6f5d8883b69122362202779f1ef8c8 | |||
| DIST gitlab-ci-multi-runner-1.0.2-amd64 31998376 SHA256 59c65be59c34d94f8b82e19013450f46fd800d89d1edf60be1fd6ac421dea0d4 SHA512 13409b232d2190604e1b752a322293eb39ba08bff37624d21c1900789a4782a54c6f9aad9a70c3ca66a136b2f4c7ba3900aab1312d9effe0c93e2d9be454d8cc WHIRLPOOL d03b0267172dad13d09b1df2436c8e040f188c80e5afb23476800b4f1db5b77e4d5a20c5458dad39943a89520668bf516eda7017625603f34e30458e890ed472 | ||||
| DIST gitlab-ci-multi-runner-1.0.2-arm 29449768 SHA256 057e3e0271f61b39d10ebf478428d608fae4b4902a6dd13fcad6b1e1fb793a38 SHA512 522b7378866830e849117ab5acf2e98892665f75c28614d4921d4c2aa06f2e6b944649eb6cf302be99e900ab46bedf37405c4564b4915d2d7b8e12d3dce68c30 WHIRLPOOL afa8880642fbba0b722ce0c2bddfd68e4f4e02ec3604eee5bbec52a4501155ae6b7eca3dcd7b02cd640cffa63235791e090d06c209f3c3316339f17d48354df3 | ||||
| DIST gitlab-ci-multi-runner-1.0.2-x86 29553888 SHA256 8937eae87d0fbad318e7867b94730bfc75e155ebd5a5f6b0783c84cf8418f84d SHA512 998dc0499d6918599f66c2a1ee3356c7bada8b819ef3d1a05449a397bab84f4294a0e875ac1a9d3fc074237d60c39b27cf26a468ccfc1ac3aaf27ffcfeab21a1 WHIRLPOOL 26f5150a7156c9000ac2c5832f948ca98d346cca25c8c6561d2be8472f31cbe19f9c6879a4d05862b95356f0fddb4ba706984b405008f6e2e96364efbb0ceac3 | ||||
| DIST gitlab-ci-multi-runner-1.0.4-amd64 31999976 SHA256 c73c22e54c1416ede6580d359af0089d9d8c8e461574543d93af2a84c91b6d38 SHA512 d96497fe6ae646d696ede7ede97a2137bb05a43c5b4c6622cb4dd612ae9d24b091ad7287d22121d7418515880f564a8af99f1d8c58ec7ea6e31a54dcb4e9274c WHIRLPOOL af78d6fdb8356062e1a3fe1e66dc3d69e0755f8ac3758884f1069cfd53b9e133f628bf244778eeefe04d227ed56fb96288e954b20d5e95f641d666534ed31926 | ||||
| DIST gitlab-ci-multi-runner-1.0.4-arm 29455296 SHA256 09e17c5f188d99d16acbe06cb01fc39c6856c6f4f8524fa4fd43291ba471beb3 SHA512 f3af90b9884d36853cc5b49b5086bbe5ac97c86b77d07bb3f47cf36c492cc024109ee9cb5135d0d671b5d1cbfb94f7473fd988d9858c6819fd031b5a98c72afa WHIRLPOOL 9107f197164cf2647ccccb4047d0397046ca30ae56be02fe4e8d29ccd2b8d5f0315c0e5fa162e38abce22ddd8ca48d6579f05674478c19b76aa47282268bd15c | ||||
| DIST gitlab-ci-multi-runner-1.0.4-x86 29555368 SHA256 47098bd380f10069829ec4b0082092324b75267e3321a85bafbdc92dc7858382 SHA512 6ae1a5e0c9e8da14f8ee5be24190e78dd5b8af12b07f622435fb15ad1405cc34749247f2b85519ac7381672a0ce7b7d5d9f4e13db189c56feb04351b060a1fa1 WHIRLPOOL a0a4647854c83a4fc24442c36f90399876d8c6d4df8d60760f10fe8d51088cb74b9087564b489c93dbd0038f3550fc0dc5b2da2eb3b08e372b0d71b9b6f8be62 | ||||
| EBUILD gitlab-ci-multi-runner-1.0.2.ebuild 2349 SHA256 6432c48b3a7a36c0b28ccab7fb79382061fa9296df9b6dc9ca32d4caa5f20702 SHA512 2a7674d506e79d8570fa8527dd10b87e775a75b4daf41458bcca28f5ad9863145571d4ebf9d9e0d9df015e48c89a7bd4a05d1bc7928223fdc2b7fd528d5282d8 WHIRLPOOL 6df8346401d631b58a3a6e1ce9f2c0e3e8b871e99880099463dcb9b5639d08b3725c7c83e7f96dfe7e8cba4e60abe77e2afbeb2c7ae8ec13cf02b05d1723fd9f | ||||
| EBUILD gitlab-ci-multi-runner-1.0.4.ebuild 2349 SHA256 6432c48b3a7a36c0b28ccab7fb79382061fa9296df9b6dc9ca32d4caa5f20702 SHA512 2a7674d506e79d8570fa8527dd10b87e775a75b4daf41458bcca28f5ad9863145571d4ebf9d9e0d9df015e48c89a7bd4a05d1bc7928223fdc2b7fd528d5282d8 WHIRLPOOL 6df8346401d631b58a3a6e1ce9f2c0e3e8b871e99880099463dcb9b5639d08b3725c7c83e7f96dfe7e8cba4e60abe77e2afbeb2c7ae8ec13cf02b05d1723fd9f | ||||
| MISC metadata.xml 234 SHA256 f35b97f99a26d73cc441e1d93bfe25aaa4e9f7f6d90c8d05a74f7b7bc5b68472 SHA512 59d8156b3ca3e99c40d5a2a32de7edf2eb53279b2424998862589d6bad77617d23fc852afec0a92f8ac5bb54a88ebc504cc0641029c1936412e90ab03dfdd447 WHIRLPOOL 935a1401910a42f888c991e443a49275ea8b87976c5aa977f670053d97d18754231749749bc92d37d4b5f45ecf65914480942a11b5827b6c08fb24313a428431 | ||||
|  |  | |||
|  | @ -0,0 +1,100 @@ | |||
| # Copyright 1999-2015 Gentoo Foundation | ||||
| # Distributed under the terms of the GNU General Public License v2 | ||||
| # $Id$ | ||||
| 
 | ||||
| EAPI="5" | ||||
| 
 | ||||
| inherit eutils user | ||||
| 
 | ||||
| DESCRIPTION="GitLab CI Multi Runner is the new build processor needed for GitLab CI >= 7.12" | ||||
| HOMEPAGE="https://gitlab.com/gitlab-org/gitlab-ci-multi-runner" | ||||
| SRC_URI="x86? ( https://${PN}-downloads.s3.amazonaws.com/v${PV}/binaries/${PN}-linux-386 -> ${P}-x86 ) | ||||
| 	amd64?    ( https://${PN}-downloads.s3.amazonaws.com/v${PV}/binaries/${PN}-linux-amd64 -> ${P}-amd64 ) | ||||
| 	arm?      ( https://${PN}-downloads.s3.amazonaws.com/v${PV}/binaries/${PN}-linux-arm -> ${P}-arm )" | ||||
| 
 | ||||
| RESTRICT="mirror" | ||||
| 
 | ||||
| LICENSE="MIT" | ||||
| SLOT="0" | ||||
| KEYWORDS="~amd64 ~x86 ~arm" | ||||
| 
 | ||||
| DEPEND="dev-vcs/git" | ||||
| RDEPEND="${DEPEND} | ||||
| 	net-libs/nodejs | ||||
| 	virtual/mta" | ||||
| 
 | ||||
| MY_NAME="${PN}" | ||||
| MY_USER="gitlab_ci_multi_runner" | ||||
| 
 | ||||
| DEST_DIR="/opt/${MY_NAME}" | ||||
| LOGS_DIR="/var/log/${MY_NAME}" | ||||
| TEMP_DIR="/var/tmp/${MY_NAME}" | ||||
| RUN_DIR="/run/${MY_NAME}" | ||||
| 
 | ||||
| pkg_setup() { | ||||
| 	enewgroup ${MY_USER} | ||||
| 	enewuser ${MY_USER} -1 /bin/bash ${DEST_DIR} ${MY_USER} | ||||
| } | ||||
| 
 | ||||
| src_unpack() { | ||||
| 	local a="$(usev amd64)$(usev arm)$(usev x86)" | ||||
| 	mkdir -p "${S}" | ||||
| 	cp "${DISTDIR}/${P}-${a}" "${S}/${PN}" | ||||
| } | ||||
| 
 | ||||
| src_prepare() { | ||||
| 	chmod +x "${S}/${PN}" | ||||
| } | ||||
| 
 | ||||
| src_compile() { | ||||
| 	# nothing to compile, binary all-in-one goodness! (?) | ||||
| 	: | ||||
| } | ||||
| 
 | ||||
| src_install() { | ||||
| 	local dest=${DEST_DIR} | ||||
| 	local conf="/etc/gitlab-runner" | ||||
| 
 | ||||
| 	diropts -m755 | ||||
| 	dodir ${dest} | ||||
| 
 | ||||
| 	exeinto ${dest} | ||||
| 	doexe "${S}/${PN}" | ||||
| 
 | ||||
| 	disopts -m750 | ||||
| 	dodir ${conf} | ||||
| 
 | ||||
| 	dosym ${conf} ${dest}/.gitlab-runner | ||||
| 
 | ||||
| 	# fix permissions | ||||
| 	fowners -R ${MY_USER}:${MY_USER} ${dest} ${conf} | ||||
| 
 | ||||
| 	## RC script ## | ||||
| 
 | ||||
| 	local rcscript="${MY_NAME}.init" | ||||
| 
 | ||||
| 	cp "${FILESDIR}/${rcscript}" "${T}" || die | ||||
| 	sed -i \ | ||||
| 		-e "s|@USER@|${MY_USER}|" \ | ||||
| 		"${T}/${rcscript}" \ | ||||
| 		|| die "failed to filter ${rcscript}" | ||||
| 
 | ||||
| 	newinitd "${T}/${rcscript}" "${MY_NAME}" | ||||
| 	newconfd "${FILESDIR}/${MY_NAME}.conf" "${MY_NAME}" | ||||
| } | ||||
| 
 | ||||
| pkg_postinst() { | ||||
| 	elog | ||||
| 	elog "If this is a fresh install of GitLab CI Multi Runner, please configure it" | ||||
| 	elog "with the following command:" | ||||
| 	elog "        emerge --config \"=${CATEGORY}/${PF}\"" | ||||
| } | ||||
| 
 | ||||
| pkg_config() { | ||||
| 	einfo "You need to register the runner with your GitLab CI instance. Please" | ||||
| 	einfo "Follow the instructions on" | ||||
| 	einfo | ||||
| 	einfo "https://gitlab.com/gitlab-org/gitlab-ci-multi-runner/blob/master/docs/install/linux-manually.md" | ||||
| 	einfo | ||||
| 	einfo "Perhaps I'll improve the ebuild later ... kthxbye." | ||||
| } | ||||
|  | @ -1,9 +1,12 @@ | |||
| AUX fix-Makefile-0.6.2.patch 377 SHA256 f0212d01760418cc669c0727310644b18a3736fac2830d82e38489af6b3a673d SHA512 6d43a4fe8250114bccc9a06cf2d970ec87da3f8fa13024a65cc0af54cce690b52c0a9907d8b219d26a1cc1ae04348e8922f4e5bf35c9b6f2b4e18efaba4b2643 WHIRLPOOL e7e05822830005dd81839510cc38dda599b84204a4eaf90ffa36ae8b96ca9e4f1e54fff34ae7a70bd92ff60d43494b5ee82fcc1b56ac37dfff2bb700a0b4ff40 | ||||
| AUX fix-Makefile-0.6.3.patch 377 SHA256 14051ee1b2fa6c4a458b402c486f0b6800004f93ce46410ab7b94142acdf6ca4 SHA512 b127b962667e5e68bece6beb8a26b86425da3f481c8f29a358043d7284796bb3c7563f9272fa27d7b4521e92bac663d55111759a68a6b3729551dbfee43303ba WHIRLPOOL e21c5f0855130ad2efd8526c4fd96e130fdb18eca81590aa0e4d535e3908a182f1bfed9ebfdacfa07698317b76e1584118f48bcdab6af85daac4a8446432a144 | ||||
| AUX fix-Makefile-0.6.4.patch 377 SHA256 b9711a6ddb3a6bbcdfc69acae43f26a86f148572535d218f910bdce19683b3c5 SHA512 c7776450f64d0037f24965708490abb553524a9ff17dee90d98ed5ecce17e02a8cf3af872c0aef40e8169d39e318d9673e7d2c2f7555a48b7a2ca71b0131691f WHIRLPOOL c9c78a79ddf7c0060039ac1ffeeb10701a9cd1bba91cdd6e74b1759f166d8ed4137bab38d28d3822167ee9d6e2a6e73557b49b1a9dffa34dca224496492dc3d9 | ||||
| AUX gitlab-workhorse.conf 248 SHA256 6d11d63aa869cfd8c6f77c3a875984c226db633be899ad7ce97fafe94236eee7 SHA512 234213c8361702bdfeea40bd306b5899de19f34ce985e090a86e01aa601cf4ed23da4dfb75f74fe5986bbea5535a7a6a745406b4f67f79d352bd1c863777c7f1 WHIRLPOOL 8ac1134cde3aee942466d206e703ebd5330f83537d7e29641447f812d857bcc57b07fbf82eab086c0d622750694f64fabf8ffca2ba26a725f61b40fd1941e963 | ||||
| AUX gitlab-workhorse.init 653 SHA256 f38c37ed818cb8c25fb800bfcb5448f659e876b78ea33ea7a1ba3c80e73ea95e SHA512 2667997def39e6dc17e6a1d9be06d6e855d5d3e956e64d93bb3e74bbad0a1d427dc034f9c139f3b05e2666abab014404b2c8013c5347f4ec25fbf5ef86e7e88e WHIRLPOOL 63cd7ff80d88676b44c2d6ccdadf74907d5f8e4268f03ee11775c423bf95955f9d3aaeedd79fa6e0486b2d225336eb2ffa165dd7b9ac87ed0c2d403dc7e5afb4 | ||||
| DIST gitlab-workhorse-0.6.2.tar.bz2 25745 SHA256 ecaea12915758a226aa0877ca57bff2c1c32009bc5aa95735fac1dfac1e2d217 SHA512 05ed31336588a7158e4c27dbea22cddeadcb84296ef8809d5824ded2f9cf5a13631997f13843a2da3bed1b9184e92c23f71d4e0382dcc45a8d209d43783b6905 WHIRLPOOL dc9ba82ca9515f569919674b8214f553d66cc08ce45674676646b9d527c7d37f9d72eb01e76c195b1981b3d2b6af378ed77fde8853e953457a2e31c0e0bf4f8e | ||||
| DIST gitlab-workhorse-0.6.3.tar.bz2 26460 SHA256 4b73e28077e0f6d19eb4bed431c90aa029b18519fa6b43ab896400d5a2bd05ee SHA512 0f46da59bc83daa49a2854ce14e449b2a6556efc166a078b20fe95bd573792cf2894a4e67472206c2d56735c1c95dfde615c158d3e430ae701d670316870a29c WHIRLPOOL e09e085cf93817517ad6cdb072c41b9a5a2b6822f2018423ef78fd7e501af3993d0d915ef95c524ae495f12d8c9296f5a460b37bfb0bf1a7d09cfa3d15d92822 | ||||
| DIST gitlab-workhorse-0.6.4.tar.bz2 26511 SHA256 cd71a0de525a3bf4e4d66723c1c47263aff37901e2e48a6ec7e8282f369cace7 SHA512 ecb2fd204a58ddee39ea51c38919bfa37ff745ba686c0aa6b31fcac6c3056f318dfe862871713f964e82cf916ca4a7934db094c720befa4c0a4c66722a59f977 WHIRLPOOL 7417f2adb601c0bd28c7e3758e1f03b7f7dc044e0df6794100015687cfd253d2567b7344cff50b8fef999542032d01233a44f724f9b527203e57e5a8b3b65ca0 | ||||
| EBUILD gitlab-workhorse-0.6.2.ebuild 866 SHA256 92cde2ed28248dbb4f9ebfeed5bc79999fbbb06a64b979c77d7c27896a4f9c85 SHA512 f4e140aeb09c423fae606e50f596991bdf61b1e1ef6c2e966d0dba00a0331c72c075899e1fcb44f28037f4523d54fbf56775cc4c7d59e55de9e0a7e6a5332768 WHIRLPOOL 9c5ba94be5144a6ea5d78536e3d62faa92772c61ea21c3ec6d25db499982651813c9926be7b8fc1ae52d4428e5ced901f69ced3801f902188aeea4d12ea9b4c6 | ||||
| EBUILD gitlab-workhorse-0.6.3.ebuild 866 SHA256 dc2863afba82390633afb85cc199dced0234d504ce051fbcbb919b99871e6262 SHA512 2e4982d6219139326a19756e1ea35f7c9cda2c45e0d21391234a48cf9cb7615ea66707d3ca054ca5f8329ff2c208b77972e5f3c02fbefa6b4c63a586481895fd WHIRLPOOL bf3c0ce0379550953c790e24fd5251fe8f8fbfb05caf8a4ddfca00e1ea03108517c92509b90523e872611e70300e4787cc4983c191f805ea96808bc71a0dfb48 | ||||
| EBUILD gitlab-workhorse-0.6.4.ebuild 866 SHA256 ca2a291f5d2217676c13d610cb925c649deb64e88cd81bfb26c03a2a4ca1c49d SHA512 8684cf00d8768fc051800ddd099805a3a13995bbafa27a638c71a3cb4fdcfad5b2325ef5c7074d74b951ab2e348b50943dc432858c701b796f1ec323c2e854bb WHIRLPOOL d19614d96eb38249d520459fc4c361812850069f9fc905ffe7590e5d9a54576847ccc35b99b18251426c6e16014ff2e8f7e96dd1d6a6963b11cba7c48395763f | ||||
| MISC metadata.xml 234 SHA256 f35b97f99a26d73cc441e1d93bfe25aaa4e9f7f6d90c8d05a74f7b7bc5b68472 SHA512 59d8156b3ca3e99c40d5a2a32de7edf2eb53279b2424998862589d6bad77617d23fc852afec0a92f8ac5bb54a88ebc504cc0641029c1936412e90ab03dfdd447 WHIRLPOOL 935a1401910a42f888c991e443a49275ea8b87976c5aa977f670053d97d18754231749749bc92d37d4b5f45ecf65914480942a11b5827b6c08fb24313a428431 | ||||
|  |  | |||
							
								
								
									
										12
									
								
								dev-vcs/gitlab-workhorse/files/fix-Makefile-0.6.4.patch
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								dev-vcs/gitlab-workhorse/files/fix-Makefile-0.6.4.patch
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,12 @@ | |||
| diff --git a/Makefile b/Makefile
 | ||||
| index c81222f..1a90927 100644
 | ||||
| --- a/Makefile
 | ||||
| +++ b/Makefile
 | ||||
| @@ -1,5 +1,5 @@
 | ||||
| -PREFIX=/usr/local
 | ||||
| -VERSION=$(shell git describe)-$(shell date -u +%Y%m%d.%H%M%S)
 | ||||
| +PREFIX=${DESTDIR}/usr
 | ||||
| +VERSION=0.6.4-$(shell date -u +%Y%m%d.%H%M%S)
 | ||||
|  GOBUILD=go build -ldflags "-X main.Version=${VERSION}" | ||||
|   | ||||
|  all: gitlab-zip-cat gitlab-zip-metadata gitlab-workhorse | ||||
							
								
								
									
										38
									
								
								dev-vcs/gitlab-workhorse/gitlab-workhorse-0.6.4.ebuild
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										38
									
								
								dev-vcs/gitlab-workhorse/gitlab-workhorse-0.6.4.ebuild
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,38 @@ | |||
| # Copyright 1999-2015 Gentoo Foundation | ||||
| # Distributed under the terms of the GNU General Public License v2 | ||||
| # $Id$ | ||||
| 
 | ||||
| EAPI="5" | ||||
| 
 | ||||
| inherit eutils user | ||||
| 
 | ||||
| DESCRIPTION="This is the new backend for Git-over-HTTP communication needed for GitLab >= 8.4" | ||||
| HOMEPAGE="https://gitlab.com/gitlab-org/gitlab-workhorse" | ||||
| SRC_URI="https://gitlab.com/gitlab-org/${PN}/repository/archive.tar.bz2?ref=${PV} -> ${P}.tar.bz2" | ||||
| S="${WORKDIR}/${P}-3f8da4ae570ca6e79c795f343dad278d60edd343" | ||||
| RESTRICT="mirror" | ||||
| 
 | ||||
| LICENSE="MIT" | ||||
| SLOT="0" | ||||
| KEYWORDS="~amd64 ~x86" | ||||
| 
 | ||||
| DEPEND=">=dev-lang/go-1.5.1 | ||||
| 	!dev-vcs/gitlab-git-http-server" | ||||
| 
 | ||||
| src_prepare() { | ||||
| 	epatch "${FILESDIR}/fix-Makefile-${PV}.patch" | ||||
| } | ||||
| 
 | ||||
| src_install() { | ||||
| 	local dest=/usr/bin | ||||
| 
 | ||||
| 	diropts -m755 | ||||
| 	dodir ${dest} | ||||
| 
 | ||||
| 	exeinto ${dest} | ||||
| 	doexe "${S}/${PN}" | ||||
| 
 | ||||
| 	## RC script ## | ||||
| 	newinitd "${FILESDIR}/${PN}.init" "${PN}" | ||||
| 	newconfd "${FILESDIR}/${PN}.conf" "${PN}" | ||||
| } | ||||
|  | @ -1,3 +1,5 @@ | |||
| DIST FeedReader-1.2.1.tar.gz 970118 SHA256 cb24d6dcef46080f2aa61fdc1b0187a8c52aedf913e6f63325ee46c631e5c87a SHA512 386c4c137bb4abba918e4f987666358ebe3926b0d4d3b466648d2679efd218376baf1ff58c987dfff953e9b6f084a47db34df8044a3a64ecb1f8e560f0f09e74 WHIRLPOOL 3e6f62c18ffb1dbe669f969b76de496463a49804c3da5d9e35e8726e4cef45552291c94b33cf3129805720cacc51953d60dfb4b54658344c261b412f29ab847f | ||||
| EBUILD feedreader-1.2.1.ebuild 1443 SHA256 8f076117efa49d072585369b5b480df112e49bbe2c23691d620074d3992f08ed SHA512 fa970a752e02dcc111d64e8594ee4e28535a1716137259fe85f6c95f6af4b68da4287ac0c25778ef33197ebbeae8178dba45f04007e0ad3e2ee22a99ab247e69 WHIRLPOOL 0e7414e3f63ac7f0212829d46e45bc57aa77c53994e5c82df311f27f5b9007a92497ae5aeaa7adcb4e8c3941536f56f40c6dd3215007cffe2d0221a1eb003b08 | ||||
| DIST FeedReader-1.4.3.tar.gz 1097255 SHA256 e43ceb9eb866c2e8e16d460b6914e6450b2c97fe62f0730a2ec67a3c7d7f0a3c SHA512 bb4057608bbc7c5c5e92decc3222950f13cf6dc5fb1338f661b3f990a68b3ff28f7ecd3b68a90139fc4d4f90c0fa7b193a94a8819e10092a3d37f33a284640be WHIRLPOOL 316a8b6f599dd4c64800e040ebe11f7e9b702a1f2a762b32c0f35ca8098ef3fd35a1ca7ea77c362b0a0eb6450f42d39b1a8c112e8096d1b4af98b2e372b2d23f | ||||
| EBUILD feedreader-1.2.1-r1.ebuild 1443 SHA256 eb134c2603b871ae9b84796985056189156eb519b1d6a4e56e19a1e22ccf40a7 SHA512 c2d46936133aee10000d5d076908334587d968ca75bdb92b7735564620407287c964201298e661f2e0be704d80e44ae68ecd46418ec4c3de16dd6b326a1e41a7 WHIRLPOOL ae9ae971caac69a136fc3ea5f0103c89c2e7d935dc0589a07a15e5dcc57d46dc0ccd1edca5f6699dadbf2c676db17db60b6da95fa8c143746e6cc2281ec49a39 | ||||
| EBUILD feedreader-1.4.3.ebuild 1432 SHA256 66ea321c389c080f3eb448ee35adba864e93c73b476b9156e7f90b3907a4b47d SHA512 695a82048e272cf0fd6b768c8e0694646e11c31e33bc03377b16f139575eeb53f446c69b9896232c6e082609b0a79ab15e3b27d4339dad7f063221ea662a7e7c WHIRLPOOL 259ada7f1794a8f653d80325611dbf8abd73564718db45c04065591398f0666a72d8796cacabf5eb0e708fc82df058d49840ab54a2f90e2629832b896c3fce04 | ||||
| MISC metadata.xml 338 SHA256 065c970f65dc2d874999563e23f1cd3b3eb7d81b3858c7c9fed5ede9c9230d03 SHA512 9f668348e070853e0b24d1bf8f18dcc33d80f40f8d70fe7363b6d008f3a1e841b14a3cadf94e40643b39b4fec18bb06df5ae0a3412b96cc5c43a8c5fe7aa1f19 WHIRLPOOL 51094d7ce385f827f140171e796cfa35a0acc4e69d6c5eea5e305af79be3c255d5d8d1b08fdb219a54e9771b6d8311a03845c1ef1ca4076cd93617d16cb35ed6 | ||||
|  |  | |||
|  | @ -7,7 +7,7 @@ EAPI="5" | |||
| inherit cmake-utils gnome2 vala | ||||
| 
 | ||||
| CMAKE_MIN_VERSION="2.6" | ||||
| VALA_MIN_API_VERSION="0.24" | ||||
| VALA_MIN_API_VERSION="0.26" | ||||
| 
 | ||||
| MY_P="FeedReader" | ||||
| 
 | ||||
							
								
								
									
										79
									
								
								net-news/feedreader/feedreader-1.4.3.ebuild
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										79
									
								
								net-news/feedreader/feedreader-1.4.3.ebuild
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,79 @@ | |||
| # Copyright 1999-2015 Gentoo Foundation | ||||
| # Distributed under the terms of the GNU General Public License v2 | ||||
| # $Id$ | ||||
| 
 | ||||
| EAPI="5" | ||||
| 
 | ||||
| inherit cmake-utils gnome2 vala | ||||
| 
 | ||||
| CMAKE_MIN_VERSION="2.6" | ||||
| VALA_MIN_API_VERSION="0.26" | ||||
| 
 | ||||
| MY_P="FeedReader" | ||||
| 
 | ||||
| DESCRIPTION="Simple News Feed Reader for feeds aggregated by Tiny Tiny RSS or feedly" | ||||
| HOMEPAGE="https://github.com/jangernert/${MY_P}" | ||||
| SRC_URI="https://launchpad.net/${PN}/1.4/${PV}/+download/${MY_P}-${PV}.tar.gz" | ||||
| 
 | ||||
| LICENSE="GPL-2" | ||||
| SLOT="0" | ||||
| KEYWORDS="~amd64" | ||||
| 
 | ||||
| IUSE="+gnome webkit4" | ||||
| 
 | ||||
| RDEPEND=">=x11-libs/gtk+-3.12:3 | ||||
| 	app-text/html2text | ||||
| 	$(vala_depend) | ||||
| 	dev-libs/json-glib | ||||
| 	dev-libs/libgee:0.8 | ||||
| 	net-libs/libsoup:2.4 | ||||
| 	dev-db/sqlite:3 | ||||
| 	app-crypt/libsecret | ||||
| 	x11-libs/libnotify | ||||
| 	dev-libs/libxml2 | ||||
| 	net-libs/rest:0.7 | ||||
| 	!webkit4? ( net-libs/webkit-gtk:3 ) | ||||
| 	webkit4? ( net-libs/webkit-gtk:4 ) | ||||
| 	dev-libs/gobject-introspection | ||||
| 	gnome? ( gnome-base/gnome-keyring )" | ||||
| 
 | ||||
| DEPEND="${RDEPEND} | ||||
| 	dev-util/intltool | ||||
| 	virtual/pkgconfig" | ||||
| 
 | ||||
| S="${WORKDIR}" | ||||
| 
 | ||||
| src_prepare() { | ||||
| 	vala_src_prepare | ||||
| } | ||||
| 
 | ||||
| src_configure() { | ||||
| 	local mycmakeargs=( | ||||
| 		-DWITH_LIBUNITY=OFF | ||||
| 		-DVALA_EXECUTABLE="${VALAC}" | ||||
| 		-DCMAKE_INSTALL_PREFIX="${PREFIX}" | ||||
| 		-DGSETTINGS_LOCALINSTALL=OFF | ||||
| 	) | ||||
| 	$(cmake-utils_use_use webkit4 WEBKIT_4) | ||||
| 	cmake-utils_src_configure | ||||
| } | ||||
| 
 | ||||
| src_compile() { | ||||
| 	cmake-utils_src_compile | ||||
| } | ||||
| 
 | ||||
| src_install() { | ||||
| 	cmake-utils_src_install | ||||
| } | ||||
| 
 | ||||
| pkg_preinst() { | ||||
| 	gnome2_pkg_preinst | ||||
| } | ||||
| 
 | ||||
| pkg_postinst() { | ||||
| 	gnome2_pkg_postinst | ||||
| } | ||||
| 
 | ||||
| pkg_postrm() { | ||||
| 	gnome2_pkg_postrm | ||||
| } | ||||
|  | @ -7,6 +7,10 @@ AUX gitlab-unicorn.service 773 SHA256 010c9e223a30400d9155b39499eb0d7efad23b66ba | |||
| AUX gitlab-workhorse.service 930 SHA256 09348a52fec333b4b19828752e0484400c1efa9dfb644723fcf8e80537e294b6 SHA512 6332024fe0049287899cf482b6e4439e9dd90da14e489d08aa8e5e79cb7872efcc517d99b69fa23b011b382acb1e5926496a78f08af5d2d64daa515b869a0c6a WHIRLPOOL 3749c6719b2a35c7de29763cd616e1e9cc30a85aa1630ffc46440334459b5922503d52629556c125a6dd6574bdc5f23f1b2a7f2a85e2270a415b22246e0b6bae | ||||
| AUX gitlab.conf 27 SHA256 cd9be088bbb67a5400407fc6f63c061eb224f16748b7d0812ff2c101f43ca263 SHA512 909c49fee6d050c1e94b2559ff2a9d54c5c346492be0e2920b50d56d69eaddbed67e3ac12e012d2a9601b5596640ebf33c8dc68fc588a03ca370d963294be37f WHIRLPOOL fa436e8d7d2643d450259d26b6e7b24dae69df47ed22e5ef2a567f37aa785fbf3b0eb1129ae7c8bf8986c29559fc3b744a34064375e5245dce2b10053cd715d9 | ||||
| DIST gitlab-ce-8.4.3.tar.gz 12187867 SHA256 bc11494885c6ad41f2b6a057d7fbec2fd4df10908f591c84c210f4881aa3c23d SHA512 84018eca604ba1639e19cc45b6ef21ad298cf60a66724bc247bf7a7c94ff1131010317d851855f5676687e8c8148602ad199e35f1029ebab24ccbbafd7b866e1 WHIRLPOOL 418afc8ddb262aa7af22bd79cb9febf1a15625f753208fe4f47cbbc3d79df0566e506febe2917bd2176508312d4a5da7245e36233ec2e50c024b811c1d306b00 | ||||
| DIST gitlab-ce-8.4.4.tar.gz 12186833 SHA256 f8c403d4cecd82aa2021ed5a6d5d7b4ac8526c7ee7a9bb1c7391f8653bf5a01c SHA512 fe8bd002ea164b384e25303e06ab6a6a97c89180a1898bc8a6d6bb07fcfda6be03a057ad7f92e4c192e0c10aa686b897fe18e864b36c314dcd7fee62dd6758bb WHIRLPOOL 8c79ba70f9b56408f70a4b48554114bcad5a4ac2806dfd8fe63ad060b9887bb6cf3d4f5c2d6e7db20aa65a83e2c33879fd32b9cce7277cd6fdd65acbdb399f40 | ||||
| DIST gitlab-ce-8.5.0.tar.gz 14276001 SHA256 a43dd64cfb1e34bf273d31984b52ada09c5a48d5d077f5bd1f21a79960bb1039 SHA512 499d93767df9d3c9c4b68ac663846d49335bd989ee8e93a8d610cb6106900886913912443f908cd316424312df67658df5d6027fda9a5abd787572d4e23e14d1 WHIRLPOOL 225c40c9a1769dbd13ea736f6bdce2a9a3cd5bfca8b27ce9270f55beebd36f5b233858c0dee5f0d80cdf40c5ccc1af651d152743f5ede1f98a8a8496ba36b6d1 | ||||
| EBUILD gitlab-ce-8.4.3.ebuild 11158 SHA256 134fedd2c467d11174a22055e58c822b953f9bdb9902aa0bdf0822c66344d364 SHA512 818c37d814074cb063c91adcfde0f1164fa89cba5a855c442470b5f0e47256f2078326f998b5502c996bf4a2c874cdc068685ad037d1dcf962c2c0bbe683e689 WHIRLPOOL a251afe289ab12dbef9114ebfcb00cf84080766e4d0c1737fa1ece1965210d4544a319af27823b4794c0bddc0cfbf6d3cb896bbe48fa02c623e0b4847b6302d2 | ||||
| EBUILD gitlab-ce-9999.ebuild 11174 SHA256 ba795484b7c5c134b63047f8f88e62ff3be2de28357d223c235c881831c92853 SHA512 6102ec75e6d5e86e7241b9524863a2bc3b2fd1922464a5d1fc9454e2aff38caa20ae609bdf1b10a8870891bce9f00a9905d5b00e2bc73329d5a83e3a27f015c6 WHIRLPOOL 6c7bc32f975d7bf1b69f57c8bc6f2aaff376292ee344a4b3be68616986975b5a4fe56f7d8d60adcd7ffeaa79a89d8586503cd723154db22ca3c04bcf03e2e929 | ||||
| EBUILD gitlab-ce-8.4.4.ebuild 11158 SHA256 134fedd2c467d11174a22055e58c822b953f9bdb9902aa0bdf0822c66344d364 SHA512 818c37d814074cb063c91adcfde0f1164fa89cba5a855c442470b5f0e47256f2078326f998b5502c996bf4a2c874cdc068685ad037d1dcf962c2c0bbe683e689 WHIRLPOOL a251afe289ab12dbef9114ebfcb00cf84080766e4d0c1737fa1ece1965210d4544a319af27823b4794c0bddc0cfbf6d3cb896bbe48fa02c623e0b4847b6302d2 | ||||
| EBUILD gitlab-ce-8.5.0.ebuild 11158 SHA256 b04a3e9bb4e562c05d04ee840581a6509af67c87b57b265b953e11c992fbf0ad SHA512 69b49eb9a847e81fbb89471ee25bd9aafe33d2f00b739248884989e2055578ce78ad1af60d113ba934fc5b26ad46b2a5df972f5cfa6fa307389652a50e37247b WHIRLPOOL 32658138ff627ffc10442239a375135aaad53b0a91ad5417550ea2682e77a454eeac44f379d63427310de9f32bb75f7d4c56d679dae6744bfe2970ab87c5aa28 | ||||
| EBUILD gitlab-ce-9999.ebuild 11174 SHA256 5d4812ff14eef908c89087869e08757f786a96d4a97f2c019b7b6079e13e3ae6 SHA512 296856dcf0b79a37204a42379a344ef62415a3e7867382e5e1e65cdd7aa0befa3ff15a9b5e2663ce1461ec696746b1f8a833e33278c7dbc659778331a4e9963e WHIRLPOOL 2698b9502aa45fcf7a2a0e2b32a088ad39d03af73559b66c143e37afc7f6d5447d5458cdd198ec51596ca1134d0b7334513f19b82407ff336365fe875c10b828 | ||||
| MISC metadata.xml 545 SHA256 1b7fc44d811e1ab7638fe4a40253f49d5f1071872d3020c22c4f67662750cb2f SHA512 86f47d297892bccfefa087d93936296f5647993a9ec8e3f47907a6859cbf385e5bc6f00502d7836c9e8d9efef2b6725bf145b0150924c2082b2bd164469ef6ea WHIRLPOOL 6bfb8a55684d68c8bfa6e025a0be965f7b815394ee0896dd2a13cfb524e3cf3f3149acc9072897e30a1842060389576aac07ea8beb4a8b0bfc3e8eab3723f2a1 | ||||
|  |  | |||
							
								
								
									
										370
									
								
								www-apps/gitlab-ce/gitlab-ce-8.4.4.ebuild
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										370
									
								
								www-apps/gitlab-ce/gitlab-ce-8.4.4.ebuild
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,370 @@ | |||
| # Copyright 1999-2015 Gentoo Foundation | ||||
| # Distributed under the terms of the GNU General Public License v2 | ||||
| # $Id$ | ||||
| 
 | ||||
| EAPI="5" | ||||
| 
 | ||||
| # Maintainer notes: | ||||
| # - This ebuild uses Bundler to download and install all gems in deployment mode | ||||
| #   (i.e. into isolated directory inside application). That's not Gentoo way how | ||||
| #   it should be done, but GitLab has too many dependencies that it will be too | ||||
| #   difficult to maintain them via ebuilds. | ||||
| # | ||||
| 
 | ||||
| USE_RUBY="ruby21" | ||||
| 
 | ||||
| inherit eutils ruby-ng user systemd | ||||
| 
 | ||||
| MY_PKGNAME="gitlabhq" | ||||
| 
 | ||||
| DESCRIPTION="GitLab is a free project and repository management application" | ||||
| HOMEPAGE="https://about.gitlab.com/" | ||||
| SRC_URI="https://github.com/${MY_PKGNAME}/${MY_PKGNAME}/archive/v${PV}.tar.gz -> ${P}.tar.gz" | ||||
| RUBY_S="${MY_PKGNAME}-${PV}" | ||||
| 
 | ||||
| RESTRICT="mirror" | ||||
| 
 | ||||
| LICENSE="MIT" | ||||
| SLOT="0" | ||||
| KEYWORDS="~amd64 ~x86" | ||||
| IUSE="kerberos mysql +postgres +unicorn systemd rugged_use_system_libraries" | ||||
| 
 | ||||
| ## Gems dependencies: | ||||
| #   charlock_holmes		dev-libs/icu | ||||
| #   grape, capybara		dev-libs/libxml2, dev-libs/libxslt | ||||
| #   rugged				dev-util/cmake, virtual/pkgconfig | ||||
| #   json				dev-util/ragel | ||||
| #   pygments.rb			python 2.7+ | ||||
| #   execjs				net-libs/nodejs, or any other JS runtime | ||||
| #   pg					dev-db/postgresql | ||||
| #   mysql				virtual/mysql | ||||
| # | ||||
| GEMS_DEPEND=" | ||||
| 	dev-libs/icu | ||||
| 	dev-libs/libxml2 | ||||
| 	dev-libs/libxslt | ||||
| 	dev-util/ragel | ||||
| 	net-libs/nodejs | ||||
| 	postgres? ( >=dev-db/postgresql-9.1:* ) | ||||
| 	mysql? ( virtual/mysql ) | ||||
| 	kerberos? ( virtual/krb5 )" | ||||
| CDEPEND=" | ||||
| 	dev-util/cmake | ||||
| 	virtual/pkgconfig" | ||||
| DEPEND="${GEMS_DEPEND} | ||||
| 	>=dev-vcs/gitlab-shell-2.6.10 | ||||
| 	dev-vcs/git | ||||
| 	>=dev-vcs/gitlab-workhorse-0.6.2 | ||||
| 	kerberos? ( !app-crypt/heimdal ) | ||||
| 	rugged_use_system_libraries? ( net-libs/http-parser dev-libs/libgit2:0/23 )" | ||||
| RDEPEND="${DEPEND} | ||||
| 	>=dev-db/redis-2.8 | ||||
| 	virtual/mta | ||||
| 	systemd? ( sys-apps/systemd:0= )" | ||||
| ruby_add_bdepend " | ||||
| 	virtual/rubygems | ||||
| 	>=dev-ruby/bundler-1.0" | ||||
| 
 | ||||
| # | ||||
| # fix-sendmail-config: | ||||
| #     Fix default settings to work with ssmtp that doesn't know '-t' argument. | ||||
| # | ||||
| RUBY_PATCHES=( | ||||
| 	"${PN}-fix-sendmail-config.patch" | ||||
| ) | ||||
| 
 | ||||
| MY_NAME="gitlab" | ||||
| MY_USER="git"    # should be same as in gitlab-shell | ||||
| 
 | ||||
| DEST_DIR="/opt/${MY_NAME}" | ||||
| CONF_DIR="/etc/${MY_NAME}" | ||||
| LOGS_DIR="/var/log/${MY_NAME}" | ||||
| TEMP_DIR="/var/tmp/${MY_NAME}" | ||||
| 
 | ||||
| # When updating ebuild to newer version, check list of the queues in | ||||
| # https://gitlab.com/gitlab-org/gitlab-ce/blob/v${PV}/bin/background_jobs | ||||
| SIDEKIQ_QUEUES="post_receive,mailers,archive_repo,system_hook,project_web_hook,gitlab_shell,incoming_email,runner,common,default" | ||||
| 
 | ||||
| all_ruby_prepare() { | ||||
| 	# fix paths | ||||
| 	local satellites_path="${TEMP_DIR}/repo_satellites" | ||||
| 	local repos_path=/var/lib/git/repositories | ||||
| 	local shell_path=/usr/share/gitlab-shell | ||||
| 	sed -i -E \ | ||||
| 		-e "/satellites:$/,/\w:$/   s|(\s*path:\s).*|\1${satellites_path}/|" \ | ||||
| 		-e "/gitlab_shell:$/,/\w:$/ s|(\s*path:\s).*|\1${shell_path}/|" \ | ||||
| 		-e "/gitlab_shell:$/,/\w:$/ s|(\s*repos_path:\s).*|\1${repos_path}/|" \ | ||||
| 		-e "/gitlab_shell:$/,/\w:$/ s|(\s*hooks_path:\s).*|\1${shell_path}/hooks/|" \ | ||||
| 		config/gitlab.yml.example || die "failed to filter gitlab.yml.example" | ||||
| 
 | ||||
| 	local run_path=/run/${MY_NAME} | ||||
| 	sed -i -E \ | ||||
| 		-e "s|/home/git/gitlab/tmp/(pids\|sockets)|${run_path}|" \ | ||||
| 		-e "s|/home/git/gitlab/log|${LOGS_DIR}|" \ | ||||
| 		-e "s|/home/git/gitlab|${DEST_DIR}|" \ | ||||
| 		config/unicorn.rb.example || die "failed to filter unicorn.rb.example" | ||||
| 
 | ||||
| 	sed -i \ | ||||
| 		-e "s|/home/git/gitlab/tmp/sockets|${run_path}|" \ | ||||
| 		lib/support/nginx/gitlab || die "failed to filter nginx/gitlab" | ||||
| 
 | ||||
| 	# modify default database settings for PostgreSQL | ||||
| 	sed -i -E \ | ||||
| 		-e 's|(username:).*|\1 gitlab|' \ | ||||
| 		-e 's|(password:).*|\1 gitlab|' \ | ||||
| 		-e 's|(socket:).*|\1 /run/postgresql/.s.PGSQL.5432|' \ | ||||
| 		config/database.yml.postgresql \ | ||||
| 		|| die "failed to filter database.yml.postgresql" | ||||
| 
 | ||||
| 	# rename config files | ||||
| 	mv config/gitlab.yml.example config/gitlab.yml | ||||
| 	mv config/unicorn.rb.example config/unicorn.rb | ||||
| 
 | ||||
| 	local dbconf=config/database.yml | ||||
| 	if use postgres && ! use mysql; then | ||||
| 		mv ${dbconf}.postgresql ${dbconf} | ||||
| 		rm ${dbconf}.mysql | ||||
| 	elif use mysql && ! use postgres; then | ||||
| 		mv ${dbconf}.mysql ${dbconf} | ||||
| 		rm ${dbconf}.postgresql | ||||
| 	fi | ||||
| 
 | ||||
| 	# remove useless files | ||||
| 	rm -r lib/support/{deploy,init.d} | ||||
| 	use unicorn || rm config/unicorn.rb | ||||
| } | ||||
| 
 | ||||
| all_ruby_install() { | ||||
| 	local dest=${DEST_DIR} | ||||
| 	local conf=${CONF_DIR} | ||||
| 	local logs=${LOGS_DIR} | ||||
| 	local temp=${TEMP_DIR} | ||||
| 
 | ||||
| 	# prepare directories | ||||
| 	diropts -m750 | ||||
| 	dodir ${logs} ${temp} | ||||
| 
 | ||||
| 	diropts -m755 | ||||
| 	dodir ${conf} ${dest}/public/uploads | ||||
| 
 | ||||
| 	dosym ${temp} ${dest}/tmp | ||||
| 	dosym ${logs} ${dest}/log | ||||
| 
 | ||||
| 	# install configs | ||||
| 	insinto ${conf} | ||||
| 	doins -r config/* | ||||
| 	dosym ${conf} ${dest}/config | ||||
| 
 | ||||
| 	echo 'export RAILS_ENV=production' > "${D}/${dest}/.profile" | ||||
| 
 | ||||
| 	# remove needless dirs | ||||
| 	rm -Rf config tmp log | ||||
| 
 | ||||
| 	# install the rest files | ||||
| 	# using cp 'cause doins is slow | ||||
| 	cp -Rl * "${D}/${dest}"/ | ||||
| 
 | ||||
| 	# install logrotate config | ||||
| 	dodir /etc/logrotate.d | ||||
| 	cat > "${D}/etc/logrotate.d/${MY_NAME}" <<-EOF | ||||
| 		${logs}/*.log { | ||||
| 		    missingok | ||||
| 		    delaycompress | ||||
| 		    compress | ||||
| 		    copytruncate | ||||
| 		} | ||||
| 	EOF | ||||
| 
 | ||||
| 	## Install gems via bundler ## | ||||
| 
 | ||||
| 	cd "${D}/${dest}" | ||||
| 
 | ||||
| 	local without="development test aws" | ||||
| 	local flag; for flag in mysql postgres unicorn kerberos; do | ||||
| 		without+="$(use $flag || echo ' '$flag)" | ||||
| 	done | ||||
| 	local bundle_args="--deployment ${without:+--without ${without}}" | ||||
| 
 | ||||
| 	use "rugged_use_system_libraries" && export RUGGED_USE_SYSTEM_LIBRARIES="YES" | ||||
| 
 | ||||
| 	einfo "Running bundle install ${bundle_args} ..." | ||||
| 	${RUBY} /usr/bin/bundle install ${bundle_args} || die "bundler failed" | ||||
| 
 | ||||
| 	# clean gems cache | ||||
| 	rm -Rf vendor/bundle/ruby/*/cache | ||||
| 	rm -Rf vendor/bundle/ruby/*/bundler/gems/charlock_holmes-dde194609b35/.git | ||||
| 
 | ||||
| 	# fix permissions | ||||
| 	fowners -R ${MY_USER}:${MY_USER} ${dest} ${temp} ${logs} | ||||
| 
 | ||||
| 	## RC script ## | ||||
| 
 | ||||
| 	if use systemd ; then | ||||
| 		ewarn "Beware: systemd support has not been tested, use at your own risk!" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-sidekiq.service" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-unicorn.service" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-workhorse.service" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-mailroom.service" | ||||
| 		systemd_dotmpfilesd "${FILESDIR}/gitlab.conf" | ||||
| 	else | ||||
| 		local rcscript=gitlab-sidekiq-8.2.init | ||||
| 		use unicorn && rcscript=gitlab-unicorn-8.2.init | ||||
| 
 | ||||
| 		cp "${FILESDIR}/${rcscript}" "${T}" || die | ||||
| 		sed -i \ | ||||
| 			-e "s|@USER@|${MY_USER}|" \ | ||||
| 			-e "s|@GITLAB_BASE@|${dest}|" \ | ||||
| 			-e "s|@LOGS_DIR@|${logs}|" \ | ||||
| 			-e "s|@QUEUES@|${SIDEKIQ_QUEUES}|" \ | ||||
| 			"${T}/${rcscript}" \ | ||||
| 			|| die "failed to filter ${rcscript}" | ||||
| 
 | ||||
| 		newinitd "${T}/${rcscript}" "${MY_NAME}" | ||||
| 	fi | ||||
| } | ||||
| 
 | ||||
| pkg_postinst() { | ||||
| 	elog "If this is an update from a previous version, stop your GitLab" | ||||
| 	elog "instance and issue the following command to perform all required" | ||||
| 	elog "migrations:" | ||||
| 	elog "       emerge --config \"=${CATEGORY}/${PF}\"" | ||||
| 	elog "PLEASE NOTE: It's HIGHLY recommended to backup your database" | ||||
| 	elog "before running the config phase!" | ||||
| 	elog | ||||
| 	elog "If this was a fresh install, follow these steps:" | ||||
| 	elog | ||||
| 	elog "1. Configure your GitLab's settings in ${CONF_DIR}/gitlab.yml." | ||||
| 	elog | ||||
| 	elog "2. Configure your database settings in ${CONF_DIR}/database.yml" | ||||
| 	elog "   for \"production\" environment." | ||||
| 	elog | ||||
| 	elog "3. Then you should create a database for your GitLab instance, if you" | ||||
| 	elog "haven't done so already." | ||||
| 	elog | ||||
| 	if use postgres; then | ||||
| 		elog "If you have local PostgreSQL running, just copy&run:" | ||||
| 		elog "      su postgres" | ||||
| 		elog "      psql -c \"CREATE ROLE gitlab PASSWORD 'gitlab' \\" | ||||
| 		elog "          NOSUPERUSER NOCREATEDB NOCREATEROLE INHERIT LOGIN;\"" | ||||
| 		elog "      createdb -E UTF-8 -O gitlab gitlabhq_production" | ||||
| 		elog "  Note: You should change your password to something more random..." | ||||
| 		elog | ||||
| 	fi | ||||
| 	elog "4. Finally execute the following command to initlize environment:" | ||||
| 	elog "       emerge --config \"=${CATEGORY}/${PF}\"" | ||||
| 	elog "   Note: Do not forget to start Redis server first!" | ||||
| 	elog | ||||
| 	elog "If you're running GitLab behind an SSL proxy such as nginx or Apache and" | ||||
| 	elog "you can't login after the upgrade, be sure to read the section about the" | ||||
| 	elog "verification of the CSRF token in GitLab's trouble-shooting guide at" | ||||
| 	elog "http://goo.gl/5XGRGv." | ||||
| } | ||||
| 
 | ||||
| pkg_config() { | ||||
| 	local shell_conf='/etc/gitlab-shell.yml' | ||||
| 
 | ||||
| 	einfo "Checking configuration files" | ||||
| 
 | ||||
| 	if [ ! -r "${CONF_DIR}/database.yml" ]; then | ||||
| 		eerror "Copy ${CONF_DIR}/database.yml.* to" | ||||
| 		eerror "${CONF_DIR}/database.yml and edit this file in order to configure your" | ||||
| 		eerror "database settings for \"production\" environment."; die | ||||
| 	fi | ||||
| 
 | ||||
| 	# check gitlab-shell configuration | ||||
| 	if [ -r ${shell_conf} ]; then | ||||
| 		local shell_repos_path="$(ryaml ${shell_conf} repos_path)" | ||||
| 		local gitlab_repos_path="$(ryaml ${CONF_DIR}/gitlab.yml \ | ||||
| 			production gitlab_shell repos_path)" | ||||
| 
 | ||||
| 		if [ ! "${shell_repos_path}" -ef "${gitlab_repos_path}" ]; then | ||||
| 			eerror "repos_path in ${CONF_DIR}/gitlab.yml and ${shell_conf}" | ||||
| 			eerror "must points to the same location! Fix the repos_path location and" | ||||
| 			eerror "run this again."; die | ||||
| 		fi | ||||
| 	else | ||||
| 		ewarn "GitLab Shell checks skipped, could not find config file at" | ||||
| 		ewarn "${shell_conf}. Make sure that you have gitlab-shell properly" | ||||
| 		ewarn "installed and that repos_path is the same as in GitLab." | ||||
| 	fi | ||||
| 
 | ||||
| 	local email_from="$(ryaml ${CONF_DIR}/gitlab.yml production gitlab email_from)" | ||||
| 	local git_home="$(egethome ${MY_USER})" | ||||
| 
 | ||||
| 	# configure Git global settings | ||||
| 	if [ ! -e "${git_home}/.gitconfig" ]; then | ||||
| 		einfo "Setting git user" | ||||
| 		su -l ${MY_USER} -c " | ||||
| 			git config --global user.email '${email_from}'; | ||||
| 			git config --global user.name 'GitLab'" \ | ||||
| 			|| die "failed to setup git name and email" | ||||
| 	fi | ||||
| 
 | ||||
| 	if [ ! -d "${DEST_DIR}/.git" ]; then | ||||
| 		# create dummy git repo as workaround for | ||||
| 		# https://github.com/bundler/bundler/issues/2039 | ||||
| 		einfo "Initializing dummy git repository to avoid false errors from bundler" | ||||
| 		su -l ${MY_USER} -c " | ||||
| 			cd ${DEST_DIR} | ||||
| 			git init | ||||
| 			git add README.md | ||||
| 			git commit -m 'Dummy repository'" >/dev/null | ||||
| 	fi | ||||
| 
 | ||||
| 	## Initialize app ## | ||||
| 
 | ||||
| 	local RAILS_ENV="production" | ||||
| 	local RUBY=${RUBY:-/usr/bin/ruby} | ||||
| 	local BUNDLE="${RUBY} /usr/bin/bundle" | ||||
| 
 | ||||
| 	local dbname="$(ryaml ${CONF_DIR}/database.yml production database)" | ||||
| 
 | ||||
| 	if [ -f "${DEST_DIR}/.secret" ]; then | ||||
| 		local update=true | ||||
| 
 | ||||
| 		einfo "Migrating database ..." | ||||
| 		exec_rake db:migrate | ||||
| 
 | ||||
| 		# https://github.com/gitlabhq/gitlabhq/issues/5311#issuecomment-31656496 | ||||
| 		einfo "Migrating iids ..." | ||||
| 		exec_rake migrate_iids | ||||
| 
 | ||||
| 		einfo "Cleaning old precompiled assets ..." | ||||
| 		exec_rake assets:clean | ||||
| 
 | ||||
| 		einfo "Cleaning cache ..." | ||||
| 		exec_rake cache:clear | ||||
| 	else | ||||
| 		local update=false | ||||
| 
 | ||||
| 		einfo "Initializing database ..." | ||||
| 		exec_rake gitlab:setup | ||||
| 	fi | ||||
| 
 | ||||
| 	einfo "Precompiling assests ..." | ||||
| 	exec_rake assets:precompile | ||||
| 
 | ||||
| 	if [ "${update}" = 'true' ]; then | ||||
| 		ewarn | ||||
| 		ewarn "This configuration script runs only common migration tasks." | ||||
| 		ewarn "Please read guides on" | ||||
| 		ewarn "    https://github.com/gitlabhq/gitlabhq/blob/master/doc/update/" | ||||
| 		ewarn "for any additional migration tasks specific to your previous GitLab" | ||||
| 		ewarn "version." | ||||
| 	fi | ||||
| } | ||||
| 
 | ||||
| ryaml() { | ||||
| 	ruby -ryaml -e 'puts ARGV[1..-1].inject(YAML.load(File.read(ARGV[0]))) {|acc, key| acc[key] }' "$@" | ||||
| } | ||||
| 
 | ||||
| exec_rake() { | ||||
| 	local command="${BUNDLE} exec rake $@ RAILS_ENV=${RAILS_ENV}" | ||||
| 
 | ||||
| 	echo "   ${command}" | ||||
| 	su -l ${MY_USER} -c " | ||||
| 		export LANG=en_US.UTF-8; export LC_ALL=en_US.UTF-8 | ||||
| 		cd ${DEST_DIR} | ||||
| 		${command}" \ | ||||
| 		|| die "failed to run rake $@" | ||||
| } | ||||
							
								
								
									
										370
									
								
								www-apps/gitlab-ce/gitlab-ce-8.5.0.ebuild
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										370
									
								
								www-apps/gitlab-ce/gitlab-ce-8.5.0.ebuild
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,370 @@ | |||
| # Copyright 1999-2015 Gentoo Foundation | ||||
| # Distributed under the terms of the GNU General Public License v2 | ||||
| # $Id$ | ||||
| 
 | ||||
| EAPI="5" | ||||
| 
 | ||||
| # Maintainer notes: | ||||
| # - This ebuild uses Bundler to download and install all gems in deployment mode | ||||
| #   (i.e. into isolated directory inside application). That's not Gentoo way how | ||||
| #   it should be done, but GitLab has too many dependencies that it will be too | ||||
| #   difficult to maintain them via ebuilds. | ||||
| # | ||||
| 
 | ||||
| USE_RUBY="ruby21" | ||||
| 
 | ||||
| inherit eutils ruby-ng user systemd | ||||
| 
 | ||||
| MY_PKGNAME="gitlabhq" | ||||
| 
 | ||||
| DESCRIPTION="GitLab is a free project and repository management application" | ||||
| HOMEPAGE="https://about.gitlab.com/" | ||||
| SRC_URI="https://github.com/${MY_PKGNAME}/${MY_PKGNAME}/archive/v${PV}.tar.gz -> ${P}.tar.gz" | ||||
| RUBY_S="${MY_PKGNAME}-${PV}" | ||||
| 
 | ||||
| RESTRICT="mirror" | ||||
| 
 | ||||
| LICENSE="MIT" | ||||
| SLOT="0" | ||||
| KEYWORDS="~amd64 ~x86" | ||||
| IUSE="kerberos mysql +postgres +unicorn systemd rugged_use_system_libraries" | ||||
| 
 | ||||
| ## Gems dependencies: | ||||
| #   charlock_holmes		dev-libs/icu | ||||
| #   grape, capybara		dev-libs/libxml2, dev-libs/libxslt | ||||
| #   rugged				dev-util/cmake, virtual/pkgconfig | ||||
| #   json				dev-util/ragel | ||||
| #   pygments.rb			python 2.7+ | ||||
| #   execjs				net-libs/nodejs, or any other JS runtime | ||||
| #   pg					dev-db/postgresql | ||||
| #   mysql				virtual/mysql | ||||
| # | ||||
| GEMS_DEPEND=" | ||||
| 	dev-libs/icu | ||||
| 	dev-libs/libxml2 | ||||
| 	dev-libs/libxslt | ||||
| 	dev-util/ragel | ||||
| 	net-libs/nodejs | ||||
| 	postgres? ( >=dev-db/postgresql-9.1:* ) | ||||
| 	mysql? ( virtual/mysql ) | ||||
| 	kerberos? ( virtual/krb5 )" | ||||
| CDEPEND=" | ||||
| 	dev-util/cmake | ||||
| 	virtual/pkgconfig" | ||||
| DEPEND="${GEMS_DEPEND} | ||||
| 	>=dev-vcs/gitlab-shell-2.6.10 | ||||
| 	dev-vcs/git | ||||
| 	>=dev-vcs/gitlab-workhorse-0.6.4 | ||||
| 	kerberos? ( !app-crypt/heimdal ) | ||||
| 	rugged_use_system_libraries? ( net-libs/http-parser dev-libs/libgit2:0/24 )" | ||||
| RDEPEND="${DEPEND} | ||||
| 	>=dev-db/redis-2.8 | ||||
| 	virtual/mta | ||||
| 	systemd? ( sys-apps/systemd:0= )" | ||||
| ruby_add_bdepend " | ||||
| 	virtual/rubygems | ||||
| 	>=dev-ruby/bundler-1.0" | ||||
| 
 | ||||
| # | ||||
| # fix-sendmail-config: | ||||
| #     Fix default settings to work with ssmtp that doesn't know '-t' argument. | ||||
| # | ||||
| RUBY_PATCHES=( | ||||
| 	"${PN}-fix-sendmail-config.patch" | ||||
| ) | ||||
| 
 | ||||
| MY_NAME="gitlab" | ||||
| MY_USER="git"    # should be same as in gitlab-shell | ||||
| 
 | ||||
| DEST_DIR="/opt/${MY_NAME}" | ||||
| CONF_DIR="/etc/${MY_NAME}" | ||||
| LOGS_DIR="/var/log/${MY_NAME}" | ||||
| TEMP_DIR="/var/tmp/${MY_NAME}" | ||||
| 
 | ||||
| # When updating ebuild to newer version, check list of the queues in | ||||
| # https://gitlab.com/gitlab-org/gitlab-ce/blob/v${PV}/bin/background_jobs | ||||
| SIDEKIQ_QUEUES="post_receive,mailers,archive_repo,system_hook,project_web_hook,gitlab_shell,incoming_email,runner,common,default" | ||||
| 
 | ||||
| all_ruby_prepare() { | ||||
| 	# fix paths | ||||
| 	local satellites_path="${TEMP_DIR}/repo_satellites" | ||||
| 	local repos_path=/var/lib/git/repositories | ||||
| 	local shell_path=/usr/share/gitlab-shell | ||||
| 	sed -i -E \ | ||||
| 		-e "/satellites:$/,/\w:$/   s|(\s*path:\s).*|\1${satellites_path}/|" \ | ||||
| 		-e "/gitlab_shell:$/,/\w:$/ s|(\s*path:\s).*|\1${shell_path}/|" \ | ||||
| 		-e "/gitlab_shell:$/,/\w:$/ s|(\s*repos_path:\s).*|\1${repos_path}/|" \ | ||||
| 		-e "/gitlab_shell:$/,/\w:$/ s|(\s*hooks_path:\s).*|\1${shell_path}/hooks/|" \ | ||||
| 		config/gitlab.yml.example || die "failed to filter gitlab.yml.example" | ||||
| 
 | ||||
| 	local run_path=/run/${MY_NAME} | ||||
| 	sed -i -E \ | ||||
| 		-e "s|/home/git/gitlab/tmp/(pids\|sockets)|${run_path}|" \ | ||||
| 		-e "s|/home/git/gitlab/log|${LOGS_DIR}|" \ | ||||
| 		-e "s|/home/git/gitlab|${DEST_DIR}|" \ | ||||
| 		config/unicorn.rb.example || die "failed to filter unicorn.rb.example" | ||||
| 
 | ||||
| 	sed -i \ | ||||
| 		-e "s|/home/git/gitlab/tmp/sockets|${run_path}|" \ | ||||
| 		lib/support/nginx/gitlab || die "failed to filter nginx/gitlab" | ||||
| 
 | ||||
| 	# modify default database settings for PostgreSQL | ||||
| 	sed -i -E \ | ||||
| 		-e 's|(username:).*|\1 gitlab|' \ | ||||
| 		-e 's|(password:).*|\1 gitlab|' \ | ||||
| 		-e 's|(socket:).*|\1 /run/postgresql/.s.PGSQL.5432|' \ | ||||
| 		config/database.yml.postgresql \ | ||||
| 		|| die "failed to filter database.yml.postgresql" | ||||
| 
 | ||||
| 	# rename config files | ||||
| 	mv config/gitlab.yml.example config/gitlab.yml | ||||
| 	mv config/unicorn.rb.example config/unicorn.rb | ||||
| 
 | ||||
| 	local dbconf=config/database.yml | ||||
| 	if use postgres && ! use mysql; then | ||||
| 		mv ${dbconf}.postgresql ${dbconf} | ||||
| 		rm ${dbconf}.mysql | ||||
| 	elif use mysql && ! use postgres; then | ||||
| 		mv ${dbconf}.mysql ${dbconf} | ||||
| 		rm ${dbconf}.postgresql | ||||
| 	fi | ||||
| 
 | ||||
| 	# remove useless files | ||||
| 	rm -r lib/support/{deploy,init.d} | ||||
| 	use unicorn || rm config/unicorn.rb | ||||
| } | ||||
| 
 | ||||
| all_ruby_install() { | ||||
| 	local dest=${DEST_DIR} | ||||
| 	local conf=${CONF_DIR} | ||||
| 	local logs=${LOGS_DIR} | ||||
| 	local temp=${TEMP_DIR} | ||||
| 
 | ||||
| 	# prepare directories | ||||
| 	diropts -m750 | ||||
| 	dodir ${logs} ${temp} | ||||
| 
 | ||||
| 	diropts -m755 | ||||
| 	dodir ${conf} ${dest}/public/uploads | ||||
| 
 | ||||
| 	dosym ${temp} ${dest}/tmp | ||||
| 	dosym ${logs} ${dest}/log | ||||
| 
 | ||||
| 	# install configs | ||||
| 	insinto ${conf} | ||||
| 	doins -r config/* | ||||
| 	dosym ${conf} ${dest}/config | ||||
| 
 | ||||
| 	echo 'export RAILS_ENV=production' > "${D}/${dest}/.profile" | ||||
| 
 | ||||
| 	# remove needless dirs | ||||
| 	rm -Rf config tmp log | ||||
| 
 | ||||
| 	# install the rest files | ||||
| 	# using cp 'cause doins is slow | ||||
| 	cp -Rl * "${D}/${dest}"/ | ||||
| 
 | ||||
| 	# install logrotate config | ||||
| 	dodir /etc/logrotate.d | ||||
| 	cat > "${D}/etc/logrotate.d/${MY_NAME}" <<-EOF | ||||
| 		${logs}/*.log { | ||||
| 		    missingok | ||||
| 		    delaycompress | ||||
| 		    compress | ||||
| 		    copytruncate | ||||
| 		} | ||||
| 	EOF | ||||
| 
 | ||||
| 	## Install gems via bundler ## | ||||
| 
 | ||||
| 	cd "${D}/${dest}" | ||||
| 
 | ||||
| 	local without="development test aws" | ||||
| 	local flag; for flag in mysql postgres unicorn kerberos; do | ||||
| 		without+="$(use $flag || echo ' '$flag)" | ||||
| 	done | ||||
| 	local bundle_args="--deployment ${without:+--without ${without}}" | ||||
| 
 | ||||
| 	use "rugged_use_system_libraries" && export RUGGED_USE_SYSTEM_LIBRARIES="YES" | ||||
| 
 | ||||
| 	einfo "Running bundle install ${bundle_args} ..." | ||||
| 	${RUBY} /usr/bin/bundle install ${bundle_args} || die "bundler failed" | ||||
| 
 | ||||
| 	# clean gems cache | ||||
| 	rm -Rf vendor/bundle/ruby/*/cache | ||||
| 	rm -Rf vendor/bundle/ruby/*/bundler/gems/charlock_holmes-dde194609b35/.git | ||||
| 
 | ||||
| 	# fix permissions | ||||
| 	fowners -R ${MY_USER}:${MY_USER} ${dest} ${temp} ${logs} | ||||
| 
 | ||||
| 	## RC script ## | ||||
| 
 | ||||
| 	if use systemd ; then | ||||
| 		ewarn "Beware: systemd support has not been tested, use at your own risk!" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-sidekiq.service" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-unicorn.service" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-workhorse.service" | ||||
| 		systemd_dounit "${FILESDIR}/gitlab-mailroom.service" | ||||
| 		systemd_dotmpfilesd "${FILESDIR}/gitlab.conf" | ||||
| 	else | ||||
| 		local rcscript=gitlab-sidekiq-8.2.init | ||||
| 		use unicorn && rcscript=gitlab-unicorn-8.2.init | ||||
| 
 | ||||
| 		cp "${FILESDIR}/${rcscript}" "${T}" || die | ||||
| 		sed -i \ | ||||
| 			-e "s|@USER@|${MY_USER}|" \ | ||||
| 			-e "s|@GITLAB_BASE@|${dest}|" \ | ||||
| 			-e "s|@LOGS_DIR@|${logs}|" \ | ||||
| 			-e "s|@QUEUES@|${SIDEKIQ_QUEUES}|" \ | ||||
| 			"${T}/${rcscript}" \ | ||||
| 			|| die "failed to filter ${rcscript}" | ||||
| 
 | ||||
| 		newinitd "${T}/${rcscript}" "${MY_NAME}" | ||||
| 	fi | ||||
| } | ||||
| 
 | ||||
| pkg_postinst() { | ||||
| 	elog "If this is an update from a previous version, stop your GitLab" | ||||
| 	elog "instance and issue the following command to perform all required" | ||||
| 	elog "migrations:" | ||||
| 	elog "       emerge --config \"=${CATEGORY}/${PF}\"" | ||||
| 	elog "PLEASE NOTE: It's HIGHLY recommended to backup your database" | ||||
| 	elog "before running the config phase!" | ||||
| 	elog | ||||
| 	elog "If this was a fresh install, follow these steps:" | ||||
| 	elog | ||||
| 	elog "1. Configure your GitLab's settings in ${CONF_DIR}/gitlab.yml." | ||||
| 	elog | ||||
| 	elog "2. Configure your database settings in ${CONF_DIR}/database.yml" | ||||
| 	elog "   for \"production\" environment." | ||||
| 	elog | ||||
| 	elog "3. Then you should create a database for your GitLab instance, if you" | ||||
| 	elog "haven't done so already." | ||||
| 	elog | ||||
| 	if use postgres; then | ||||
| 		elog "If you have local PostgreSQL running, just copy&run:" | ||||
| 		elog "      su postgres" | ||||
| 		elog "      psql -c \"CREATE ROLE gitlab PASSWORD 'gitlab' \\" | ||||
| 		elog "          NOSUPERUSER NOCREATEDB NOCREATEROLE INHERIT LOGIN;\"" | ||||
| 		elog "      createdb -E UTF-8 -O gitlab gitlabhq_production" | ||||
| 		elog "  Note: You should change your password to something more random..." | ||||
| 		elog | ||||
| 	fi | ||||
| 	elog "4. Finally execute the following command to initlize environment:" | ||||
| 	elog "       emerge --config \"=${CATEGORY}/${PF}\"" | ||||
| 	elog "   Note: Do not forget to start Redis server first!" | ||||
| 	elog | ||||
| 	elog "If you're running GitLab behind an SSL proxy such as nginx or Apache and" | ||||
| 	elog "you can't login after the upgrade, be sure to read the section about the" | ||||
| 	elog "verification of the CSRF token in GitLab's trouble-shooting guide at" | ||||
| 	elog "http://goo.gl/5XGRGv." | ||||
| } | ||||
| 
 | ||||
| pkg_config() { | ||||
| 	local shell_conf='/etc/gitlab-shell.yml' | ||||
| 
 | ||||
| 	einfo "Checking configuration files" | ||||
| 
 | ||||
| 	if [ ! -r "${CONF_DIR}/database.yml" ]; then | ||||
| 		eerror "Copy ${CONF_DIR}/database.yml.* to" | ||||
| 		eerror "${CONF_DIR}/database.yml and edit this file in order to configure your" | ||||
| 		eerror "database settings for \"production\" environment."; die | ||||
| 	fi | ||||
| 
 | ||||
| 	# check gitlab-shell configuration | ||||
| 	if [ -r ${shell_conf} ]; then | ||||
| 		local shell_repos_path="$(ryaml ${shell_conf} repos_path)" | ||||
| 		local gitlab_repos_path="$(ryaml ${CONF_DIR}/gitlab.yml \ | ||||
| 			production gitlab_shell repos_path)" | ||||
| 
 | ||||
| 		if [ ! "${shell_repos_path}" -ef "${gitlab_repos_path}" ]; then | ||||
| 			eerror "repos_path in ${CONF_DIR}/gitlab.yml and ${shell_conf}" | ||||
| 			eerror "must points to the same location! Fix the repos_path location and" | ||||
| 			eerror "run this again."; die | ||||
| 		fi | ||||
| 	else | ||||
| 		ewarn "GitLab Shell checks skipped, could not find config file at" | ||||
| 		ewarn "${shell_conf}. Make sure that you have gitlab-shell properly" | ||||
| 		ewarn "installed and that repos_path is the same as in GitLab." | ||||
| 	fi | ||||
| 
 | ||||
| 	local email_from="$(ryaml ${CONF_DIR}/gitlab.yml production gitlab email_from)" | ||||
| 	local git_home="$(egethome ${MY_USER})" | ||||
| 
 | ||||
| 	# configure Git global settings | ||||
| 	if [ ! -e "${git_home}/.gitconfig" ]; then | ||||
| 		einfo "Setting git user" | ||||
| 		su -l ${MY_USER} -c " | ||||
| 			git config --global user.email '${email_from}'; | ||||
| 			git config --global user.name 'GitLab'" \ | ||||
| 			|| die "failed to setup git name and email" | ||||
| 	fi | ||||
| 
 | ||||
| 	if [ ! -d "${DEST_DIR}/.git" ]; then | ||||
| 		# create dummy git repo as workaround for | ||||
| 		# https://github.com/bundler/bundler/issues/2039 | ||||
| 		einfo "Initializing dummy git repository to avoid false errors from bundler" | ||||
| 		su -l ${MY_USER} -c " | ||||
| 			cd ${DEST_DIR} | ||||
| 			git init | ||||
| 			git add README.md | ||||
| 			git commit -m 'Dummy repository'" >/dev/null | ||||
| 	fi | ||||
| 
 | ||||
| 	## Initialize app ## | ||||
| 
 | ||||
| 	local RAILS_ENV="production" | ||||
| 	local RUBY=${RUBY:-/usr/bin/ruby} | ||||
| 	local BUNDLE="${RUBY} /usr/bin/bundle" | ||||
| 
 | ||||
| 	local dbname="$(ryaml ${CONF_DIR}/database.yml production database)" | ||||
| 
 | ||||
| 	if [ -f "${DEST_DIR}/.secret" ]; then | ||||
| 		local update=true | ||||
| 
 | ||||
| 		einfo "Migrating database ..." | ||||
| 		exec_rake db:migrate | ||||
| 
 | ||||
| 		# https://github.com/gitlabhq/gitlabhq/issues/5311#issuecomment-31656496 | ||||
| 		einfo "Migrating iids ..." | ||||
| 		exec_rake migrate_iids | ||||
| 
 | ||||
| 		einfo "Cleaning old precompiled assets ..." | ||||
| 		exec_rake assets:clean | ||||
| 
 | ||||
| 		einfo "Cleaning cache ..." | ||||
| 		exec_rake cache:clear | ||||
| 	else | ||||
| 		local update=false | ||||
| 
 | ||||
| 		einfo "Initializing database ..." | ||||
| 		exec_rake gitlab:setup | ||||
| 	fi | ||||
| 
 | ||||
| 	einfo "Precompiling assests ..." | ||||
| 	exec_rake assets:precompile | ||||
| 
 | ||||
| 	if [ "${update}" = 'true' ]; then | ||||
| 		ewarn | ||||
| 		ewarn "This configuration script runs only common migration tasks." | ||||
| 		ewarn "Please read guides on" | ||||
| 		ewarn "    https://github.com/gitlabhq/gitlabhq/blob/master/doc/update/" | ||||
| 		ewarn "for any additional migration tasks specific to your previous GitLab" | ||||
| 		ewarn "version." | ||||
| 	fi | ||||
| } | ||||
| 
 | ||||
| ryaml() { | ||||
| 	ruby -ryaml -e 'puts ARGV[1..-1].inject(YAML.load(File.read(ARGV[0]))) {|acc, key| acc[key] }' "$@" | ||||
| } | ||||
| 
 | ||||
| exec_rake() { | ||||
| 	local command="${BUNDLE} exec rake $@ RAILS_ENV=${RAILS_ENV}" | ||||
| 
 | ||||
| 	echo "   ${command}" | ||||
| 	su -l ${MY_USER} -c " | ||||
| 		export LANG=en_US.UTF-8; export LC_ALL=en_US.UTF-8 | ||||
| 		cd ${DEST_DIR} | ||||
| 		${command}" \ | ||||
| 		|| die "failed to run rake $@" | ||||
| } | ||||
|  | @ -53,9 +53,9 @@ CDEPEND=" | |||
| DEPEND="${GEMS_DEPEND} | ||||
| 	>=dev-vcs/gitlab-shell-2.6.10 | ||||
| 	dev-vcs/git | ||||
| 	>=dev-vcs/gitlab-workhorse-0.6.3 | ||||
| 	>=dev-vcs/gitlab-workhorse-0.6.4 | ||||
| 	kerberos? ( !app-crypt/heimdal ) | ||||
| 	rugged_use_system_libraries? ( net-libs/http-parser dev-libs/libgit2:0/23 )" | ||||
| 	rugged_use_system_libraries? ( net-libs/http-parser dev-libs/libgit2:0/24 )" | ||||
| RDEPEND="${DEPEND} | ||||
| 	>=dev-db/redis-2.8 | ||||
| 	virtual/mta | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue