community/gitlab to 9.3.2-2

This commit is contained in:
Kevin Mihelich 2017-06-29 18:22:02 +00:00
parent 0fcdfa710c
commit 8cee377039

View file

@ -12,13 +12,13 @@
pkgname=gitlab pkgname=gitlab
pkgver=9.3.2 pkgver=9.3.2
pkgrel=1 pkgrel=2
pkgdesc="Project management and code hosting application" pkgdesc="Project management and code hosting application"
arch=('x86_64') arch=('x86_64')
url="https://gitlab.com/gitlab-org/gitlab-ce/tree/master#README" url="https://gitlab.com/gitlab-org/gitlab-ce/tree/master#README"
license=('MIT') license=('MIT')
depends=('ruby2.3' 'git' 'ruby2.3-bundler' 'gitlab-workhorse' 'openssh' 'redis' 'libxslt' 'icu' 'nodejs') depends=('ruby2.3' 'git' 'ruby2.3-bundler' 'gitlab-workhorse' 'openssh' 'redis' 'libxslt' 'icu' 'nodejs')
makedepends=('cmake' 'postgresql' 'mariadb' 'yarn') makedepends=('cmake' 'postgresql' 'mariadb' 'yarn' 'go')
optdepends=('postgresql: database backend' optdepends=('postgresql: database backend'
'mysql: database backend' 'mysql: database backend'
'python2-docutils: reStructuredText markup language support' 'python2-docutils: reStructuredText markup language support'
@ -81,6 +81,7 @@ prepare() {
-e "s|# path: /mnt/gitlab|path: ${_homedir}/shared|" \ -e "s|# path: /mnt/gitlab|path: ${_homedir}/shared|" \
-e "s|/home/git/gitlab-shell|/usr/share/webapps/gitlab-shell|" \ -e "s|/home/git/gitlab-shell|/usr/share/webapps/gitlab-shell|" \
-e "s|tmp/backups|${_homedir}/backups|" \ -e "s|tmp/backups|${_homedir}/backups|" \
-e "s|/home/git/gitlab/tmp/sockets/private|${_homedir}/sockets|" \
config/gitlab.yml.example > config/gitlab.yml config/gitlab.yml.example > config/gitlab.yml
msg2 "Patching paths and timeout in unicorn.rb..." msg2 "Patching paths and timeout in unicorn.rb..."
@ -125,10 +126,14 @@ build() {
cp config/resque.yml.example config/resque.yml cp config/resque.yml.example config/resque.yml
sed -i 's/url.*/nope.sock/g' config/resque.yml sed -i 's/url.*/nope.sock/g' config/resque.yml
bundle-2.3 exec rake "gitlab:gitaly:install[/tmp/gitaly]" RAILS_ENV=production
rm -rf /tmp/gitaly/_build
bundle-2.3 exec rake assets:precompile RAILS_ENV=production --trace bundle-2.3 exec rake assets:precompile RAILS_ENV=production --trace
# yarn install --production --pure-lockfile # yarn install --production --pure-lockfile
# bundle-2.3 exec rake gitlab:assets:compile RAILS_ENV=production NODE_ENV=production # bundle-2.3 exec rake gitlab:assets:compile RAILS_ENV=production NODE_ENV=production
bundle-2.3 exec rake gettext:compile RAILS_ENV=production
# After building assets, clean this up again # After building assets, clean this up again
rm config/database.yml config/database.yml.postgresql.orig rm config/database.yml config/database.yml.postgresql.orig
@ -137,11 +142,12 @@ build() {
package() { package() {
cd "${srcdir}/${_srcdir}"* cd "${srcdir}/${_srcdir}"*
depends+=('gitlab-shell>=4.0.0') depends+=('gitlab-shell')
install -d "${pkgdir}/usr/share/webapps" install -d "${pkgdir}/usr/share/webapps"
cp -r "${srcdir}/${_srcdir}"* "${pkgdir}${_datadir}" cp -r "${srcdir}/${_srcdir}"* "${pkgdir}${_datadir}"
cp -r /tmp/gitaly "${pkgdir}${_datadir}"/../gitaly # This was prepared in build()
chown -R root:root "${pkgdir}${_datadir}" chown -R root:root "${pkgdir}${_datadir}"
chmod 755 "${pkgdir}${_datadir}" chmod 755 "${pkgdir}${_datadir}"