notify_push
notify_push copied to clipboard
rc.d startup script for [Free]BSD
As a separate file, it can be included in a tar.gz/zip etc. release package during CI/CD process/jobs with the other files.
Variable based Nextcloud web root nextcloud_notify_push_droot let it set in /etc/rc.conf -> no need to edit the rc.d script itself
May I suggest changing line 32 to
binary="/${nextcloud_notify_push_droot}/apps/notify_push/bin/fbsd_amd64/notify_push"
Thanks! Done. Edit: the leading slash is in the variable already
Could you expand the setup wizard to reference this startup script when freebsd is detected?
That't the idea, I'll check out. Also noted in parallel at #153 the binary include size problem, yeah its already 3 times ~22Mbytes included in the app release package. Originally it was about the have FreeBSD rust binary compiled, which done in #254 . This PR born right after with the idea having a similar easy setup from zero.
Hello there! Wanted to ask about the status and if there is anything we can do to help with this. Thank you!
Sorry, I've completely forgot that this original PR not closed with original content/changes I've given Ive raised it. I'm using the rc.d script before the PR raised, and just replacing the binaries with new releases.
I have to check the whole scripting, I don't know what it is doing. In case anyone has the prior knowledge about this setup wizard script, please jump in. I wanted to do the things separately one by one - it seems that was the good idea :)
@icewind1991 , @thstyl2000
Please fix me: Am I in the right direction with the below idea?
Read again #273, where @GuillaumedeVolpiano was great and extended the below already:
- Binaryfinder.php
- Setup.php
- SetupWizard.php It can run & see its FB and it can result good for recognising the prebuilt binaries for FB.
So, hasSystemd() L87 needs extensions:
- check if system is FB -> if yes, check for rc.d directory & the rc.d file (?confirm overwrite here?) -> set return to 0 and exit -> plus make sure the normal bundled binary steps has added the FB rc.d script copy
- otherwise run the normal/previous code for hasSystemd()
OR, can be done one level upper, have another function hasRcd, and handle from there.
I need to see the "normal" bundled file operations yet...
Maybe it is a stupid question, but why is it needed to check for rc.d, if the system is already detected as freebsd? As far as I know, there is practically no other init system used together with freebsd. So when the setup wizard detects freebsd, it could directly write the rc script in /usr/local/etc/rc.d/ (could add a check for an already existing script, and prompting for overwrite/keep old/view diff....).
What do you think?
Not at all, I didn't know, how sure you wanna go, with how many crosschecks. Hence my beginning/closing question-marks in the brackets after the rc.d check part.
I'm in the same page: confirming FreeBSD as platform should be enough, up until there will be FreeBSD ARM releases (maybe its already there).
Edit: nor FreeBSD Arm release yet for notify_push - but two for Linux: armv7 and aarch64 -> FB has also armv7 and arm64 from 13.0 (14.0 available from Q4 last year)
Oh alright, didn't know that, thanks! I suppose then going with a hasRcd function (to keep the structure logic clear) would be better if you ask me...