Updated gitlab-shell
git-svn-id: svn+ssh://svnintern.kmrc.de/projects/gentoo/iwm-overlay@33375 cbe59ace-07ea-0310-918e-868702b5370d
This commit is contained in:
parent
f63371d63d
commit
1c4548cf26
@ -3,3 +3,4 @@ EBUILD gitlab-shell-1.9.1.ebuild 2500 SHA256 ea37fd4b4b3c526f808be1efbfaa4ea5b8f
|
||||
EBUILD gitlab-shell-1.9.4.ebuild 2500 SHA256 ea37fd4b4b3c526f808be1efbfaa4ea5b8fbd6bbaac13838016882c1df3cb1f6 SHA512 711c2e77ffa1b06c5922fcf47f8c4bb57815ff3168d13f07e15bc929976b074b0d17cfe5c85d4ef223b86e5fca25f0594a3a9666165ca045b0680617eea1e59b WHIRLPOOL 0348ca8b560414b7c2e2a366f8728cf12640dc4985f5633a46228b54d770195378f82a5a5e5476572fe1bfe6e05f9bbe9c73c244e6f11f1c3ee35c682639bf00
|
||||
EBUILD gitlab-shell-1.9.6.ebuild 2500 SHA256 a39c5a44b54c70d16f30de155020ff003fb2e9da22e44360715ada3528bac0fe SHA512 e71bd23c81d1d29c6ebdf58ae480a3ae20b0b66ceffa927e03de10a969a85921ee8088e346ed0e5783d95466d94aca5797e6507409f164d6cf17bc59ff44b843 WHIRLPOOL 93fc131e889553b3b44e7c255eb87e8b30d3941330aa969b054d0b11e6eb741fa5b1c5c2b3143a3284e2bb82443607621aa69979326cf31a412c00167c7facb0
|
||||
EBUILD gitlab-shell-2.0.1.ebuild 2633 SHA256 5ca86fbf40b7d606d5a456285437b46fd317aa94053a5e108c9830fe149cba5e SHA512 fe036c162fe78aab513aad36439cb41711248a7cc88956eee93974648ff17d973e1cd302fe73453db193eacd97d4bd93c82cb51087dff5b028d7c88793fedb71 WHIRLPOOL 5692ecf2f4e05676dc648b1159e96925b7e261704d4b8180d454e58e47bb6acca009e6e7106a76c1737fad6bb909f5ae75ac04f6a3ca54ebd8121ee78026b11b
|
||||
EBUILD gitlab-shell-2.6.0.ebuild 2633 SHA256 1a3d2460dc802d745132439c6456209362a2cfc299cae77ecf2ca0ad89499a52 SHA512 6bb0a6683ef4419ece897de8d1d3dbdc22d8116806a42830a7c11b0a73cafbf9ed4627c554e5a173a40ed3481b9b94b91d7e6a2eaca3a777c338e7fbfba3b40a WHIRLPOOL 9418c91deab2bccf55efbfcbb76da7c4180e9dbb0e61066ed0f6638a380895e12e9e4f4a15c809af0625b51e9f704414366b84475d01da4ea2af2f2ff0397580
|
||||
|
100
dev-vcs/gitlab-shell/gitlab-shell-2.6.0.ebuild
Normal file
100
dev-vcs/gitlab-shell/gitlab-shell-2.6.0.ebuild
Normal file
@ -0,0 +1,100 @@
|
||||
# Copyright 1999-2013 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="5"
|
||||
|
||||
EGIT_REPO_URI="https://github.com/gitlabhq/gitlab-shell.git"
|
||||
EGIT_COMMIT="v${PV}"
|
||||
USE_RUBY="ruby21"
|
||||
|
||||
inherit eutils git-2 ruby-ng user
|
||||
|
||||
DESCRIPTION="GitLab Shell is a free SSH access and repository management application"
|
||||
HOMEPAGE="https://github.com/gitlabhq/gitlab-shell"
|
||||
LICENSE="MIT"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
|
||||
DEPEND="$(ruby_implementation_depend ruby21)
|
||||
dev-vcs/git
|
||||
virtual/ssh
|
||||
dev-db/redis"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
GIT_USER="git"
|
||||
GIT_GROUP="git"
|
||||
HOME="/var/lib/git"
|
||||
REPO_DIR="${HOME}/repositories"
|
||||
AUTH_FILE="${HOME}/.ssh/authorized_keys"
|
||||
KEY_DIR=$(dirname "${AUTH_FILE}")
|
||||
DEST_DIR="/var/lib/${PN}"
|
||||
|
||||
pkg_setup() {
|
||||
|
||||
enewgroup ${GIT_GROUP}
|
||||
enewuser ${GIT_USER} -1 -1 "${HOME}" ${GIT_GROUP}
|
||||
}
|
||||
|
||||
all_ruby_unpack() {
|
||||
git-2_src_unpack
|
||||
cd ${P}
|
||||
sed -i \
|
||||
-e "s|\(user:\).*|\1 ${GIT_USER}|" \
|
||||
-e "s|\(repos_path:\).*|\1 \"${REPO_DIR}\"|" \
|
||||
-e "s|\(auth_file:\).*|\1 \"${AUTH_FILE}\"|" \
|
||||
config.yml.example || die "failed to filter config.example.yml"
|
||||
}
|
||||
|
||||
all_ruby_install() {
|
||||
|
||||
rm -Rf .git .gitignore
|
||||
|
||||
insinto ${DEST_DIR}
|
||||
touch gitlab-shell.log
|
||||
doins -r . || die
|
||||
|
||||
dosym ${DEST_DIR}/bin/gitlab-keys /usr/bin/gitlab-keys || die
|
||||
dosym ${DEST_DIR}/bin/gitlab-projects /usr/bin/gitlab-projects || die
|
||||
dosym ${DEST_DIR}/bin/gitlab-shell /usr/bin/gitlab-shell || die
|
||||
dosym ${DEST_DIR}/bin/check /usr/bin/gitlab-check || die
|
||||
|
||||
fperms 0755 ${DEST_DIR}/bin/gitlab-keys || die
|
||||
fperms 0755 ${DEST_DIR}/bin/gitlab-projects || die
|
||||
fperms 0755 ${DEST_DIR}/bin/gitlab-shell || die
|
||||
fperms 0755 ${DEST_DIR}/bin/check || die
|
||||
fperms 0755 ${DEST_DIR}/bin/create-hooks || die
|
||||
fperms 0755 ${DEST_DIR}/bin/install || die
|
||||
|
||||
fperms 0755 ${DEST_DIR}/hooks/post-receive || die
|
||||
fperms 0755 ${DEST_DIR}/hooks/pre-receive || die
|
||||
|
||||
fowners ${GIT_USER} ${DEST_DIR}/gitlab-shell.log
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
|
||||
dodir "${REPO_DIR}" || die
|
||||
|
||||
if [[ ! -d "${KEY_DIR}" ]] ; then
|
||||
mkdir "${KEY_DIR}" || die
|
||||
chmod 0700 "${KEY_DIR}" || die
|
||||
chown ${GIT_USER}:${GIT_GROUP} "${KEY_DIR}" -R || die
|
||||
fi
|
||||
|
||||
if [[ ! -e "${AUTH_FILE}" ]] ; then
|
||||
touch "${AUTH_FILE}" || die
|
||||
chmod 0600 "${AUTH_FILE}" || die
|
||||
chown ${GIT_USER}:${GIT_GROUP} "${AUTH_FILE}" || die
|
||||
fi
|
||||
|
||||
if [[ ! -d "${REPO_DIR}" ]] ; then
|
||||
mkdir "${REPO_DIR}"
|
||||
chmod ug+rwX,o-rwx "${REPO_DIR}" -R || die
|
||||
chmod ug-s,o-rwx "${REPO_DIR}" -R || die
|
||||
chown ${GIT_USER}:${GIT_GROUP} "${REPO_DIR}" -R || die
|
||||
fi
|
||||
|
||||
elog "Copy ${DEST_DIR}/config.example.yml to ${DEST_DIR}/config.yml"
|
||||
elog "and edit this file in order to configure your GitLab-Shell settings."
|
||||
}
|
Loading…
Reference in New Issue
Block a user