added ebuild for gitlab-shell-1.9.4 and corrected dependency in gitlabhq-6.9.2

This commit is contained in:
Manuel Friedli 2014-07-21 11:35:19 +02:00
parent 14e5abdbc8
commit d378f2ce08
4 changed files with 126 additions and 2 deletions

View file

@ -1,6 +1,8 @@
AUX gitlab-shell-1.8.0-redis-db-option.patch 625 SHA256 e707b05a5f81b3769ca8125695617335a9a90eb6ad6b0fd48d99a92f70c235ee SHA512 d5fc946937cb6fcff313c2c620ce24b66c0b6226b298214a36915fa5023ae33f348698ad2505e7e441adc80137dc092dd689d066dac9abbe4261a448ad85f753 WHIRLPOOL fc6365a20089cdb923af210c1f8b825e0bdb7dd539ba272efa224c214237d61bac0d9d0730f8bc9436be16fa874752aba5938e380ab1466f2a3baafaf2bc52cc
AUX gitlab-shell-1.9.3-config-paths.patch 1310 SHA256 ed66ac5622ed7e1999e528182ef37bbf5fe979cc2bfdb7e764207dbf9f84833c SHA512 00b188d322f0baede62c494f24ae664ba17ae88a21d30631d14f6639f023aa1f1aa936ae8a81f3252cb2763170b26a1ab69b562e7c401d531b7613de8d174dde WHIRLPOOL e231a1df28f9f1e3295cdc5c0904036bf861fe885b30b0a5bf79b96f7e1d7b5ce34d5e880d00ad043ea518e9f43182ef89c28ef62d9ed72ca761534b13bd3340
DIST gitlab-shell-1.9.3.tar.gz 16186 SHA256 8484554f76aea4443a9de19253a784b0164fd76230e8e1caeb6bf84df1a6a11c SHA512 4d14e731c865528650b134e493ce617b24971a927931c648253f9c3614d72eb21533f63984cb7cfc38a0201e3dfec3c2f5f57d6bd29fe791689548eecd8e9c3b WHIRLPOOL d36a79b3fed631fce5b63808a34ced5210243928209b221c18421f4a4e5af85b3476f74c4b2cbb5379a1c44a29bf7904be704bdcc5180d9d62576e6b76da60da
DIST gitlab-shell-1.9.4.tar.gz 16544 SHA256 7fa5682d1da614ca1603608ad89a582fc46097069708fc8ba9115b198bf63739 SHA512 0fc9b8d4cd334615a795ac82985a24ddf3256c9c62d460072c489b51fe9bf8ee8e738c9facf92115c2296e5b49dfe566c54060ce8e85d54db6b54937bf8f295c WHIRLPOOL a794d5b962ba55e19145b33044161012f30e1114b6ad48110bbc055790e743f3e90dca5c54df23085126ec8bc3af89c7a392f36ee321acd5f43feb979a2c6f80
DIST gitlab-shell-1.9.6.tar.gz 16648 SHA256 db326870c6aca27d8c29c99494f9a04cdcd0bbd673a4c27f9207ab885b6ed728 SHA512 22872a6e5401b19adece07755fcc14a8c22463437e36892a040ffd17d9e12a094b03481f98a404d80e3c44e0131ba95e0abe3897adfeb8014ba1a76667e1104d WHIRLPOOL 4cdc88ca7319f3d89516a087120f28fdd1ca45ef574d6eea67ab638349ca830e47ab4c6b17f138b3d707e235cab22ee9e9cb64f1513f1f2ef17a29ed9e6d143f
EBUILD gitlab-shell-1.9.3.ebuild 3381 SHA256 c62f0c0d33d004fadbc8172254ca61a04b921cad4fb21228284502ce79dbf983 SHA512 de85888a48e18210c0b3b5ce6bd36c9473e5c0d592c8657fea9c56856661cc261a3542b6cdcc4277a52d810265c73098ec81045abf2e5d33970a3116125b7719 WHIRLPOOL acf3fdedb73b8ecf025cad85bfd1503b8de796d6bc4d5c37a2ac371c4cd94c777f868cf514f201909ea660de8f6fecc02d177254764ba25ac3b75d8e5804b332
EBUILD gitlab-shell-1.9.4.ebuild 3341 SHA256 6947af19aeb95a832fc2fc7a82b021afe5a4fb3897c37cde62929125ae31f471 SHA512 ad20f6df96a12aa5afa2a659f92889a39bdd7f8a9dee8df6362d90a41e982d7d49162adc44a2d20fbd9a739f2a11dfd440fd89a611bb580d423198f0baa53578 WHIRLPOOL eca0e2d014bcc81655cec619515ad4fc3efd83a9375042a75ae5a03b048c6ea5f56f4291d30a94de9ca6fc5bdef4910ffef87d063b09f10f50b084569c629695
EBUILD gitlab-shell-1.9.6.ebuild 3341 SHA256 6947af19aeb95a832fc2fc7a82b021afe5a4fb3897c37cde62929125ae31f471 SHA512 ad20f6df96a12aa5afa2a659f92889a39bdd7f8a9dee8df6362d90a41e982d7d49162adc44a2d20fbd9a739f2a11dfd440fd89a611bb580d423198f0baa53578 WHIRLPOOL eca0e2d014bcc81655cec619515ad4fc3efd83a9375042a75ae5a03b048c6ea5f56f4291d30a94de9ca6fc5bdef4910ffef87d063b09f10f50b084569c629695

View file

@ -0,0 +1,122 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI="5"
USE_RUBY="ruby19 ruby20"
inherit eutils ruby-ng user
DESCRIPTION="SSH access and repository management for GitLab"
HOMEPAGE="https://github.com/gitlabhq/gitlab-shell"
SRC_URI="https://github.com/gitlabhq/gitlab-shell/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
DEPEND=""
RDEPEND="
dev-vcs/git
dev-db/redis
virtual/ssh"
ruby_add_bdepend "
virtual/ruby-ssl"
MERGE_TYPE="binary"
RUBY_PATCHES=(
"${PN}-1.9.3-config-paths.patch"
"${PN}-1.8.0-redis-db-option.patch"
)
GIT_USER="git"
DEST_DIR="/usr/share/${PN}"
DATA_DIR="/var/lib/git"
LOGS_DIR="/var/log/gitlab"
CONF_FILE="/etc/gitlab-shell.yml"
pkg_setup() {
enewgroup ${GIT_USER}
enewuser ${GIT_USER} -1 /bin/bash ${DATA_DIR} "${GIT_USER}"
local git_shell=$(egetshell ${GIT_USER})
if [ ! ${git_shell} -ef '/bin/bash' ]; then
ewarn "User ${GIT_USER} already exists, but with the shell ${git_shell}."
ewarn "Changing shell to /bin/bash ..."
usermod -s /bin/bash ${GIT_USER} \
|| die "failed to change login shell for ${GIT_USER}"
fi
}
all_ruby_prepare() {
# fix paths
sed -i -E \
-e "s|/home/git|${DATA_DIR}|" \
-e "s|[\# ]*(log_file: ).*|\1\"${LOGS_DIR}/gitlab-shell.log\"|" \
config.yml.example || die "failed to filter config.yml.example"
sed -i \
-e "s|File\.join(ROOT_PATH, 'config.yml')|'${CONF_FILE}'|" \
lib/gitlab_config.rb || die "failed to filter gitlab_config.rb"
}
all_ruby_install() {
# install lib
insinto ${DEST_DIR}; doins -r lib LICENSE README.md VERSION
# install scripts
exeinto ${DEST_DIR}/bin; doexe bin/*
exeinto ${DEST_DIR}/hooks; doexe hooks/*
exeinto ${DEST_DIR}/support; doexe support/*
# create symlinks to bin
local name; for name in $(basename -a bin/gitlab-*); do
dosym "${DEST_DIR}/bin/${name}" "/usr/bin/${name}"
done
insinto $(dirname ${CONF_FILE})
newins config.yml.example $(basename ${CONF_FILE})
# prepare directories
diropts -m750; dodir ${DATA_DIR}
diropts -m770; keepdir ${DATA_DIR}/repositories
diropts -m755; dodir ${LOGS_DIR}
# GitLab stupidly expects that gitlab-shell is in home of git user...
dosym ${DEST_DIR} ${DATA_DIR}/gitlab-shell
# fix permissions
fowners -R ${GIT_USER}:${GIT_USER} ${DATA_DIR} ${LOGS_DIR}
}
pkg_postinst() {
# check git home directory
local git_home=$(egethome ${GIT_USER})
if [ ! "${git_home}" -ef ${DATA_DIR} ]; then
ewarn "An authorized_keys is configured to be inside ${DATA_DIR}/.ssh,"
ewarn "but HOME of ${GIT_USER} user is located in ${git_home}. You must"
ewarn "either change the authorized_keys location in ${CONF_FILE},"
ewarn "or change home directory of ${GIT_USER} user to ${DATA_DIR}"
ewarn "and move ${git_home}/.ssh here."
ewarn
fi
local auth_dir="${git_home}/.ssh"
elog "Initializing authorized_keys file in ${auth_dir}"
mkdir -p ${auth_dir}
touch ${auth_dir}/authorized_keys
chmod -R u=rwX,go=- ${auth_dir}
chown -R ${GIT_USER}:${GIT_USER} ${auth_dir}
elog
elog "GitLab Shell was initialized. Repositories are located in"
elog "${DATA_DIR}/repositories, scripts in ${DEST_DIR}/bin."
elog "All gitlab-* scripts was symlinked to /usr/bin to be on your path."
elog
elog "You should change your gitlab_url in: ${CONF_FILE}."
}

View file

@ -37,4 +37,4 @@ DIST gitlabhq-6.8.2.tar.gz 10558471 SHA256 db9400d5ffadd3564bbee6e388c90d7f4c8f8
DIST gitlabhq-6.9.2.tar.gz 10566288 SHA256 2c01b223c3e889c7a45d3815f352c0546a337286d395e4d49df5ecedc1a57dc0 SHA512 b51b4e261666c14f782ce7edbbda24b6d32bb080c5444249f5c38e5233398b30f50a17cc8cbee18d75e57ba11ec3deeab4ffd1a6d6257c1858f8fe63e5138e54 WHIRLPOOL a3b9a8149fab69443b769aa145eb2c9a99bfc9f4a080edf0a6bd46c4771247b6f1c729bf5185e63bf63a02d654145362b7c8e9fefef6f0cdf1f4f30a32cf9dcb
EBUILD gitlabhq-6.7.5.ebuild 10983 SHA256 79fe5e03f1f03625a27d5ef398bb4d40e991c71490eda27913529bcdebf03b5d SHA512 73d035742868747f4d1dbbdce0d2892e29bbea3fd2938a66d16c9c72e3ec6075c9faa855b8a46b7970a8879e9633a25b65d70f3cc9eb77a2656bcbcca64f6008 WHIRLPOOL b8a9531f544799a141b7c6ddfaea6cce5d2643832c38326ff13bb3ed37f009b0bb1aeeba3d1d2434d2e59b43747c380ea505fbebb1a082da94a4e2322f20f4bf
EBUILD gitlabhq-6.8.2.ebuild 10605 SHA256 5a7e869aee5481f5c610c81a130ea677de4977d4fc184839b3f7ce16152dacb4 SHA512 3f63b20e111e74d183e36acaa9499287801b18e53f4a1f0e0271f2d93625bf9b311e3a1634e2426965cefd7fe9d2a86114b71ba32f91abded11bd0234ebc87f8 WHIRLPOOL 3f77d6e351f6552932efbe40af389069bda3e44933a0ab426663574ff490665e7ae9a8cfc2726e378073816de7423e8c8269e3cee01b0a64299044a1f99d4811
EBUILD gitlabhq-6.9.2.ebuild 10626 SHA256 488e0eb23fa551d6c1968f20cff1a259074d719b22a3c8d8b4c337c994756903 SHA512 38e2015a6c677013042717492087943998cb5226a06d905f47beebecde8e6c6f46a6aa605aa27c29850b6610394fb04ba8d486cc8630211fa0333b5a3bdd376a WHIRLPOOL 4831f5ac06c2c1f3a0b293e97ff615f049826c09f6b225c0a25b3cf7780bd23321381056bc4ba0f53effa90f1066202a3b991a417dc8ce77db7bca429edbfa28
EBUILD gitlabhq-6.9.2.ebuild 10626 SHA256 24d0e4410d93bce5bf9675a14b8618cc5590dc78b4b16a2a1b0b055b8d88fc6f SHA512 cb5b956a0b0699100704a66fff30c9d1706194b32f31208284b2622b81b3f612ceab17e9f6873cc97e0556f7eb009d0e9727595e72172b98b6fb91d483b3e5e4 WHIRLPOOL a7013e0dfc2ef18ad95eb060ebe301dc417e50420dad54f078625c699d0a4620ffc883ecb847030f7b2d4e590bfd2d901b72712f4a0af55bbf0ef6a78c139deb

View file

@ -45,7 +45,7 @@ GEMS_DEPEND="
postgres? ( dev-db/postgresql-base )
mysql? ( virtual/mysql )"
DEPEND="${GEMS_DEPEND}
>=dev-vcs/gitlab-shell-1.9.3
>=dev-vcs/gitlab-shell-1.9.4
dev-vcs/git"
RDEPEND="${DEPEND}
dev-db/redis