On Mon, Nov 04, 2024 at 03:26:59PM +0000, Stuart Henderson wrote: > > The daemon should probably read configuration from /etc, as per the porting > > guide, > > file. > > > > There is also some documentation and a template config file in the source > > tarball, > > which could be worth installing for reference. In my port I implemented > > this (and some other things) like in the diff below. > > > > (I remember getting these from previous ports on this list, my own has it > > too.) > > > > > > Stepan > > > > diff -ruNp monero/Makefile mymonero/Makefile > > --- monero/Makefile Sun Nov 3 22:13:47 2024 > > +++ mymonero/Makefile Sat Nov 2 20:18:01 2024 > > @@ -1,48 +1,59 @@ > > +post-install: > > + ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/monero > > + ${INSTALL_DATA_DIR} ${WRKINST}${LOCALSTATEDIR}/monero > > no point doing that in post-install, the dir is created by the > @sample mechanism > > > + ${INSTALL_DATA_DIR} ${PREFIX}/share/examples/monero > > + ${INSTALL_DATA} ${WRKSRC}/README.md ${WRKSRC}/docs/*.md\ > > + ${PREFIX}/share/doc/monero/ > > + ${INSTALL_DATA} ${WRKBUILD}/lib/libwallet.a ${PREFIX}/lib/ > > is that actually useful? I suggest not unless there's a need for it
If you're talking about libwallet.a, I don't know. Might be useful at some point if somebody ports any other Monero wallet, but it's not needed for Monero itself. If you're talking about the docs, as I said in [1], I see no point, as they're mostly dev docs, not end-user ones. [1]: https://marc.info/?l=openbsd-ports&m=172410058213444&w=2 > > + ${INSTALL_DATA} ${WRKSRC}/utils/conf/monerod.conf\ > > + $(PREFIX)/share/examples/monero/ > > > > diff -ruNp monero/pkg/monerod.rc mymonero/pkg/monerod.rc > > --- monero/pkg/monerod.rc Sun Nov 3 20:25:07 2024 > > +++ mymonero/pkg/monerod.rc Wed Aug 28 22:44:12 2024 > > @@ -2,7 +2,7 @@ > > > > daemon="${TRUEPREFIX}/bin/monerod" > > daemon_user="_monerod" > > -daemon_flags="--detach" > > +daemon_flags="--detach --config-file ${SYSCONFDIR}/monerod.conf" > > I'm not going to run this to test, but presumably --detach is a required > flag for running as a daemon, so it should go as part of "daemon", > leaving the (overridable) --config-file bit in daemon_flags. Wasn't aware we do that in some rc files. Updated tarball below. > > diff -ruNp monero/patches/patch-utils_conf_monerod_conf > > mymonero/patches/patch-utils_conf_monerod_conf > > --- monero/patches/patch-utils_conf_monerod_conf Thu Jan 1 09:00:00 1970 > > +++ mymonero/patches/patch-utils_conf_monerod_conf Fri Aug 30 18:12:53 2024 > > @@ -0,0 +1,14 @@ > > +Set correct paths in default config file. > > + > > +Index: utils/conf/monerod.conf > > +--- utils/conf/monerod.conf.orig > > ++++ utils/conf/monerod.conf > > +@@ -3,6 +3,6 @@ > > + # Boolean options such as 'no-igd' are specified as 'no-igd=1'. > > + # See 'monerod --help' for all available options. > > + > > +-data-dir=/var/lib/monero > > +-log-file=/var/log/monero/monero.log > > ++data-dir=${LOCALSTATEDIR}/monero > > /var/db/monero might be better than /var/monero I don't think so. The DB is ~300GB and /var/db is depended upon by other programs. I don't know if and how base could interact with it being in a different partition. Stepan, as for the sample config file itself, I choose not to add it in the original submission as I don't believe that extremely barebone config adds value. Leaving the config file and dev docs outside, the only thing left in post-install is libwallet.a, which isn't currently used, so I prefer to stick with the tarball I submitted (plus moving --detach into daemon).
monero.tgz
Description: application/tar-gz