geo/osrm-backend: user + rc script

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

geo/osrm-backend: user + rc script

Anthony J. Bentley-4
ok?

Index: infrastructure/db/user.list
===================================================================
RCS file: /cvs/ports/infrastructure/db/user.list,v
retrieving revision 1.319
diff -u -p -r1.319 user.list
--- infrastructure/db/user.list 9 Jul 2018 12:26:34 -0000 1.319
+++ infrastructure/db/user.list 14 Jul 2018 07:33:55 -0000
@@ -322,3 +322,4 @@ id  user group port options
 811 _openvpnusers net/openvpn_bsdauth
 812 _mactelnet _mactelnet net/mac-telnet
 813 _bitcoind _bitcoind net/bitcoin
+814 _osrm_routed _osrm_routed geo/osrm-backend
Index: geo/osrm-backend/Makefile
===================================================================
RCS file: /cvs/ports/geo/osrm-backend/Makefile,v
retrieving revision 1.1.1.1
diff -u -p -r1.1.1.1 Makefile
--- geo/osrm-backend/Makefile 6 Jul 2018 06:00:02 -0000 1.1.1.1
+++ geo/osrm-backend/Makefile 14 Jul 2018 07:33:55 -0000
@@ -5,6 +5,7 @@ COMMENT = high-performance road network
 GH_ACCOUNT = Project-OSRM
 GH_PROJECT = osrm-backend
 GH_TAGNAME = v5.18.0
+REVISION = 0
 
 CATEGORIES = geo
 
Index: geo/osrm-backend/pkg/PLIST
===================================================================
RCS file: /cvs/ports/geo/osrm-backend/pkg/PLIST,v
retrieving revision 1.1.1.1
diff -u -p -r1.1.1.1 PLIST
--- geo/osrm-backend/pkg/PLIST 6 Jul 2018 06:00:02 -0000 1.1.1.1
+++ geo/osrm-backend/pkg/PLIST 14 Jul 2018 07:33:55 -0000
@@ -1,4 +1,7 @@
 @comment $OpenBSD: PLIST,v 1.1.1.1 2018/07/06 06:00:02 bentley Exp $
+@newgroup _osrm_routed:814
+@newuser _osrm_routed:814:814:daemon:OSRM Router:${VARBASE}/empty:/sbin/nologin
+@rcscript ${RCDIR}/osrm_routed
 @bin bin/osrm-components
 @bin bin/osrm-contract
 @bin bin/osrm-customize
Index: geo/osrm-backend/pkg/osrm_routed.rc
===================================================================
RCS file: geo/osrm-backend/pkg/osrm_routed.rc
diff -N geo/osrm-backend/pkg/osrm_routed.rc
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ geo/osrm-backend/pkg/osrm_routed.rc 14 Jul 2018 07:33:55 -0000
@@ -0,0 +1,14 @@
+#!/bin/ksh
+#
+# $OpenBSD: rc.template,v 1.12 2018/01/11 19:30:18 rpe Exp $
+
+daemon="${TRUEPREFIX}/bin/osrm-routed"
+daemon_user="_osrm_routed"
+
+. /etc/rc.d/rc.subr
+
+rc_bg=YES
+rc_reload=NO
+
+
+rc_cmd $1

Reply | Threaded
Open this post in threaded view
|

Re: geo/osrm-backend: user + rc script

Klemens Nanni-2
OK

Reply | Threaded
Open this post in threaded view
|

Re: geo/osrm-backend: user + rc script

Antoine Jacoutot-7
In reply to this post by Anthony J. Bentley-4
On Sat, Jul 14, 2018 at 01:36:30AM -0600, Anthony J. Bentley wrote:

> ok?
>
> Index: infrastructure/db/user.list
> ===================================================================
> RCS file: /cvs/ports/infrastructure/db/user.list,v
> retrieving revision 1.319
> diff -u -p -r1.319 user.list
> --- infrastructure/db/user.list 9 Jul 2018 12:26:34 -0000 1.319
> +++ infrastructure/db/user.list 14 Jul 2018 07:33:55 -0000
> @@ -322,3 +322,4 @@ id  user group port options
>  811 _openvpnusers net/openvpn_bsdauth
>  812 _mactelnet _mactelnet net/mac-telnet
>  813 _bitcoind _bitcoind net/bitcoin
> +814 _osrm_routed _osrm_routed geo/osrm-backend

You need to bump the uid/gidi, it's already taken.


> Index: geo/osrm-backend/Makefile
> ===================================================================
> RCS file: /cvs/ports/geo/osrm-backend/Makefile,v
> retrieving revision 1.1.1.1
> diff -u -p -r1.1.1.1 Makefile
> --- geo/osrm-backend/Makefile 6 Jul 2018 06:00:02 -0000 1.1.1.1
> +++ geo/osrm-backend/Makefile 14 Jul 2018 07:33:55 -0000
> @@ -5,6 +5,7 @@ COMMENT = high-performance road network
>  GH_ACCOUNT = Project-OSRM
>  GH_PROJECT = osrm-backend
>  GH_TAGNAME = v5.18.0
> +REVISION = 0
>  
>  CATEGORIES = geo
>  
> Index: geo/osrm-backend/pkg/PLIST
> ===================================================================
> RCS file: /cvs/ports/geo/osrm-backend/pkg/PLIST,v
> retrieving revision 1.1.1.1
> diff -u -p -r1.1.1.1 PLIST
> --- geo/osrm-backend/pkg/PLIST 6 Jul 2018 06:00:02 -0000 1.1.1.1
> +++ geo/osrm-backend/pkg/PLIST 14 Jul 2018 07:33:55 -0000
> @@ -1,4 +1,7 @@
>  @comment $OpenBSD: PLIST,v 1.1.1.1 2018/07/06 06:00:02 bentley Exp $
> +@newgroup _osrm_routed:814
> +@newuser _osrm_routed:814:814:daemon:OSRM Router:${VARBASE}/empty:/sbin/nologin
> +@rcscript ${RCDIR}/osrm_routed
>  @bin bin/osrm-components
>  @bin bin/osrm-contract
>  @bin bin/osrm-customize
> Index: geo/osrm-backend/pkg/osrm_routed.rc
> ===================================================================
> RCS file: geo/osrm-backend/pkg/osrm_routed.rc
> diff -N geo/osrm-backend/pkg/osrm_routed.rc
> --- /dev/null 1 Jan 1970 00:00:00 -0000
> +++ geo/osrm-backend/pkg/osrm_routed.rc 14 Jul 2018 07:33:55 -0000
> @@ -0,0 +1,14 @@
> +#!/bin/ksh
> +#
> +# $OpenBSD: rc.template,v 1.12 2018/01/11 19:30:18 rpe Exp $
> +
> +daemon="${TRUEPREFIX}/bin/osrm-routed"
> +daemon_user="_osrm_routed"
> +
> +. /etc/rc.d/rc.subr
> +
> +rc_bg=YES
> +rc_reload=NO
> +
> +

Zap one line here.

> +rc_cmd $1
>

--
Antoine