Bug 237366 - www/seahub - bind address init script
Summary: www/seahub - bind address init script
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Richard Gallamore
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-04-18 20:23 UTC by Boris Tassou
Modified: 2019-06-10 17:08 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (ultima)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Boris Tassou 2019-04-18 20:23:05 UTC
Hi,

I want to Seahub listen on local host, i tried to modify gunicorn.conf[1] to :

# default localhost:8000
bind = "127.0.0.1:8000"

But nothing changed when i restart seahub.

So, i modified the init script[2] to use a variable who is already define at the beginning :

--- seahub.back 2019-04-17 15:39:11.107334000 +0200
+++ seahub      2019-04-17 12:05:06.282106000 +0200
@@ -123,7 +123,7 @@
                check_required_before;
                before_start;
                echo "Starting seahub at port ${seahub_port} ..."
-               su -m "${seafile_user}" -c "$command \"${gunicorn_exe}\" seahub.wsgi:application -c \"${gunicorn_conf}\" -b \"0.0.0.0:${seahub_port}\" --preload --chdir \"$seafile_path/seahub\""
+               su -m "${seafile_user}" -c "$command \"${gunicorn_exe}\" seahub.wsgi:application -c \"${gunicorn_conf}\" -b \"${seahub_host}:${seahub_port}\" --preload --chdir \"$seafile_path/seahub\""

        # Ensure seahub is started successfully
                sleep 5

[1] /usr/local/www/haiwen/conf/gunicorn.conf
[2] /usr/local/etc/rc.d/seahub

Thanks for the work!
Comment 1 commit-hook freebsd_committer 2019-06-09 05:48:31 UTC
A commit references this bug:

Author: ultima
Date: Sun Jun  9 05:47:27 UTC 2019
New revision: 503787
URL: https://svnweb.freebsd.org/changeset/ports/503787

Log:
  Change currently unused init var seahub_host so
  there is no breakage for current users of seahub.

  Change hard coded 0.0.0.0 for gunicorn start to
  seahub_host.

  PR:		237366
  Submitted by:	Boris Tassou <boris.tassou@sec^>

Changes:
  head/www/seahub/Makefile
  head/www/seahub/files/seahub.in
Comment 2 commit-hook freebsd_committer 2019-06-10 17:08:59 UTC
A commit references this bug:

Author: ultima
Date: Mon Jun 10 17:08:17 UTC 2019
New revision: 503918
URL: https://svnweb.freebsd.org/changeset/ports/503918

Log:
  MFH: r503784 r503787

  Bumped seahub version for init script to fix gunicorn binary name
  Fix checksum due to retagged version

  Change currently unused init var seahub_host so
  there is no breakage for current users of seahub.

  Change hard coded 0.0.0.0 for gunicorn start to
  seahub_host.

  PR:		237366 237367
  Approved by:	ports-secteam (joneum)

Changes:
_U  branches/2019Q2/
  branches/2019Q2/net-mgmt/seafile-server/Makefile.include
  branches/2019Q2/www/seahub/Makefile
  branches/2019Q2/www/seahub/distinfo
  branches/2019Q2/www/seahub/files/seahub.in