Hi,

I've set up a Gitea Server and noticed two inaccuracies in the port.

1. gitea sets up a post-receive hook which is used internally and 
   requires a bash. Without it, it errors out on the first repository 
   push.

2. After setting up the socket path as described in the README, gitea 
   doesn't start anymore. The reason is the non existent path component. 
   The socket itself is created automatically. The path component is not.

The patch below addresses both issues.

OK? (maintainer on CC)

Best Regards,
Stefan

Index: Makefile
===================================================================
RCS file: /cvs/ports/www/gitea/Makefile,v
retrieving revision 1.86
diff -u -p -u -p -r1.86 Makefile
--- Makefile    23 Dec 2022 22:09:27 -0000      1.86
+++ Makefile    7 Jan 2023 14:36:08 -0000
@@ -3,6 +3,7 @@ COMMENT =               compact self-hosted Git servi
 VERSION =              1.17.4
 DISTNAME =             gitea-src-${VERSION}
 PKGNAME =              gitea-${VERSION}
+REVISION =             0
 
 MASTER_SITES =         
https://github.com/go-gitea/gitea/releases/download/v${VERSION}/
 
@@ -27,7 +28,8 @@ MODGO_LDFLAGS += -X code.gitea.io/gitea/
 MODGO_LDFLAGS += -X main.Version=${VERSION}
 MODGO_LDFLAGS += -X 'main.Tags=${GO_TAGS}'
 
-RUN_DEPENDS =          devel/git
+RUN_DEPENDS =          devel/git \
+                       shells/bash
 
 ALL_TARGET =           code.gitea.io/gitea
 WRKSRC =               ${MODGO_WORKSPACE}/src/${ALL_TARGET}
Index: pkg/README
===================================================================
RCS file: /cvs/ports/www/gitea/pkg/README,v
retrieving revision 1.6
diff -u -p -u -p -r1.6 README
--- pkg/README  6 Mar 2022 11:05:26 -0000       1.6
+++ pkg/README  7 Jan 2023 14:36:08 -0000
@@ -55,6 +55,9 @@ Relevant configuration directives in ${S
        HTTP_ADDR              = /var/www/run/gitea/gitea.sock
        LOCAL_ROOT_URL         = %(ROOT_URL)s
 
+Create the socket path with the following command:
+# mkdir /var/www/run/gitea && chown _gitea /var/www/run/gitea
+
 Customizing gitea
 =================
 For custom public files, templates, gitignores, labels, licenses and READMEs,

Reply via email to