Date: Fri, 23 Dec 2022 13:20:04 +0000 From: bugzilla-noreply@freebsd.org To: ports-bugs@FreeBSD.org Subject: [Bug 268526] databases/neo4j: port partially broken and does not separate installation from runtime data Message-ID: <bug-268526-7788@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D268526 Bug ID: 268526 Summary: databases/neo4j: port partially broken and does not separate installation from runtime data Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: Individual Port(s) Assignee: wen@FreeBSD.org Reporter: michael.osipov@siemens.com Assignee: wen@FreeBSD.org Flags: maintainer-feedback?(wen@FreeBSD.org) I don't know where to start, there are several issues where I have a proble= m to use this port, likely I need to break up in several tickets later. (note: I have gone through this with devel/nexus2-oss as a maintainer). * It does not start, JAVA_HOME is not set in neo4j.sh since JAVA_HOME is on= ly set when the java(1) wrapper is called which isn't done in neo4j.sh: =3D=3D=3D # service neo4j start Error: JAVA_HOME is not defined correctly. We cannot execute =3D=3D=3D This I had to work around in rc.conf first (neo4j_env) * The service runs as root which is a no-go. You must reverse a uid/gid in UIDs/GIDs files. * The neo4j.conf file is never used due to misconfiguration: * Lack of separation between read-only installation and runtime data: =3D=3D=3D # service neo4j start Directories in use: home: /usr/local/neo4j config: /usr/local/neo4j/conf logs: /usr/local/neo4j/logs plugins: /usr/local/neo4j/plugins import: /usr/local/neo4j data: /usr/local/neo4j/data certificates: /usr/local/neo4j/certificates licenses: /usr/local/neo4j/licenses run: /usr/local/neo4j/run =3D=3D=3D because of =3D=3D=3D # procstat penv 43356 | grep ENV envp[13]: NEO4J_CONF_ENV=3DNEO4J_CONF=3D/usr/local/etc =3D=3D=3D does not work and does not exist: https://github.com/neo4j/neo4j/search?q=3DNEO4J_CONF_ENV This I had to work around in rc.conf first (neo4j_env). Then =3D=3D=3D Directories in use: home: /usr/local/neo4j config: /usr/local/etc logs: /var/log/neo4j plugins: /usr/local/neo4j/plugins import: /usr/local/neo4j/import data: /var/db/neo4j certificates: /usr/local/neo4j/certificates licenses: /usr/local/neo4j/licenses run: /var/run =3D=3D=3D Still, certificates doe not correspond to pkg-plist, likely licenes should = be in ETCDIR as well. * post-patch either too many vars which aren't even defined or patch-* don't add them. See missing JAVA_HOME. This is actually rooted in a bad script of= the appassembler-maven-plugin which I might address upstream somewhere in the future. Maybe even more things I haven't taken care of/noticed ATM. I used this for reference for dirs/files and ro vs rw: https://neo4j.com/docs/operations-manual/4.4/configuration/file-locations/ I am not the target neo4j user, but just the sysadmin and software develope= r. Ideally, this would would install configure /usr/local/share/java/neo4j (owned by root) =3D=3D=3D=3D=3D (owned by neo4j:neo4j) /var/db/neo4j/data /var/run/neo4j (can't be run/ because service user cannot write to run/) /var/log/neo4j /var/db/neo4j/metrics /var/db/neo4j/import =3D=3D=3D=3D=3D (owned by root) /usr/local/etc/neo4j/ /usr/local/etc/neo4j/neo4j.conf /usr/local/etc/neo4j/licenses /usr/local/etc/neo4j/certificates =3D=3D=3D=3D=3D At least this is basically how I have taken devel/nexus2-oss apart and upgrading is a snap. I'd be happy to engage into a discussion to make this right according to hier(7). --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-268526-7788>