Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 4 Feb 2020 20:34:58 +0000 (UTC)
From:      Matthias Fechner <mfechner@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r525233 - in head/www/gitlab-ce: . files
Message-ID:  <202002042034.014KYwAN094573@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mfechner
Date: Tue Feb  4 20:34:57 2020
New Revision: 525233
URL: https://svnweb.freebsd.org/changeset/ports/525233

Log:
  Use the standard RC system available in FreeBSD.
  This makes some commands like:
  service gitlab rcvar
  available. This is required by configuration management tools like Chef, Puppetm, Salt,
  Ansible and more.
  
  PR:		243860
  Reported by:	amendlik@gmail.com

Modified:
  head/www/gitlab-ce/Makefile
  head/www/gitlab-ce/files/gitlab.in

Modified: head/www/gitlab-ce/Makefile
==============================================================================
--- head/www/gitlab-ce/Makefile	Tue Feb  4 18:34:03 2020	(r525232)
+++ head/www/gitlab-ce/Makefile	Tue Feb  4 20:34:57 2020	(r525233)
@@ -3,7 +3,7 @@
 
 PORTNAME=	gitlab-ce
 PORTVERSION=	12.7.5
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	www devel
 
 MAINTAINER=	mfechner@FreeBSD.org

Modified: head/www/gitlab-ce/files/gitlab.in
==============================================================================
--- head/www/gitlab-ce/files/gitlab.in	Tue Feb  4 18:34:03 2020	(r525232)
+++ head/www/gitlab-ce/files/gitlab.in	Tue Feb  4 20:34:57 2020	(r525233)
@@ -129,14 +129,14 @@ fi
 # Switch to the app_user if it is not he/she who is running the script.
 if [ "$USER" != "$app_user" ]; then
   # Regenerate the Gemfile.lock for all related products
-  echo "Regenerate Gitlab Gemfile.lock"
+  # echo "Regenerate Gitlab Gemfile.lock"
   rm -f "${app_root}"/Gemfile.lock
   if ! su -l root -c "cd ${app_root} && %%LOCALBASE%%/bin/bundle install --local --quiet"; then
     echo "Could not create Gemfile.lock for gitlab, please report this using FreeBSD Bugtracker, https://bugs.freebsd.org/"
     exit 1
   fi
   chown git "${app_root}"/Gemfile.lock
-  echo "Regenerate Gitaly Gemfile.lock"
+  # echo "Regenerate Gitaly Gemfile.lock"
   rm -f "${gitaly_dir}"/ruby/Gemfile.lock
   if ! su -l root -c "cd ${gitaly_dir}/ruby && %%LOCALBASE%%/bin/bundle install --local --quiet"; then
     echo "Could not create Gemfile.lock for gitaly, please report this using FreeBSD Bugtracker, https://bugs.freebsd.org/"
@@ -563,56 +563,6 @@ restart_gitlab(){
 }
 
 
-### Finally the input handling.
-
-case $gitlab_enable in
-  [yY][eE][sS])
-    case "$1" in
-      start|quietstart|faststart)
-        start_gitlab
-        ;;
-      stop|faststop)
-        stop_gitlab
-        ;;
-      restart)
-        restart_gitlab
-        ;;
-      reload|force-reload)
-	reload_gitlab
-        ;;
-      status)
-        print_status
-        exit $gitlab_status
-        ;;
-      *)
-        echo "Usage: service gitlab {start|quietstart|faststop|stop|restart|reload|onestart|onestop|onerestart|onreload|status}"
-        exit 1
-        ;;
-    esac
-    ;;
-  *)
-    case "$1" in
-      onestart)
-        start_gitlab
-        ;;
-      onestop)
-        stop_gitlab
-        ;;
-      onerestart)
-        restart_gitlab
-        ;;
-      onreload)
-        reload_gitlab
-        ;;
-      status)
-        print_status
-        exit $gitlab_status
-        ;;
-      *)
-        echo "Usage: service gitlab {start|quietstart|faststop|stop|restart|reload|onestart|onestop|onerestart|onreload|status}"
-        exit 1
-        ;;
-    esac
-esac
+run_rc_command "$1"
 
 exit



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202002042034.014KYwAN094573>