|Summary:||net-mgmt/librenms reconsider default options|
|Product:||Ports & Packages||Reporter:||Dries Michiels <driesm.michiels>|
|Component:||Individual Port(s)||Assignee:||Dan Langille <dvl>|
|Severity:||Affects Only Me||CC:||dvl|
Description Dries Michiels 2019-02-22 23:18:44 UTC
Created attachment 202278 [details] APACHEMOD option default to off Hi guys, When trying a pkg install librenms it pulls in apache. I don't think this is the right call or dependency for librenms. It is true one needs a web server to make the application work although NGINX is another perfect candidate. My question is, could we make APACHEMOD default to off maybe even considering removing the option all together? Installing apache is as easy as pkg install apache24 and pkg install php_mod. Same for NGINX after intalling librenms, pkg install ... :) while it is quiet ugly that apache is installed when I want to use NGINX using packages. Thanks for considering.
Comment 1 Dan Langille 2019-07-26 23:59:13 UTC
If we set this off, should we also provide an Nginx option? if so, what? If we set this off, that's going to break POLA for some people.
Comment 2 Dries Michiels 2019-07-27 09:30:31 UTC
Well, my 2 cents, I think that we should not even provide a web server options. Because it is as easy as "pkg install 'web server I want'". This way, all the flexibility is at the users hand. You are right that this will break POLA for the people using LibreNMS with Apache. And I also have no clear path forward. At least it will require an UPDATING entry. Maybe get some buy-in from portmgr and see what they think about this?
Comment 3 Dan Langille 2020-03-03 15:44:30 UTC
This is the solution I will proceed with: * remove references to apache and mod_php from Makefile * add this entry to UPDATING: 20200303: AFFECTS: users of net-mgmt/librenms AUTHOR: dvl@FreeBSD.org 1. Apache / mod_php options removed The APACHEMOD option has been removed. LibreNMS can be used with other webservers, not just Apache. In other to simplify the port, the option was removed. Now you manually install the webserver of your preference. If upgrading from LibreNMS < 1.61, you can do this to prevent 'pkg autoremove' from uninstalling Apache / mod_php: $ sudo pkg set -A 0 apache24 mod_php74 Mark apache24-2.4.41 as not automatically installed? [y/N]: y Mark mod_php74-7.4.3 as not automatically installed? [y/N]: y Adjust mod_php74 to suit the version of mod_php you have. 2. include/defaults.inc.php is gone The file include/defaults.inc.php is no longer distributed by the upstream project. The FreeBSD port patched this file to correct the paths to common tools such as ping, snmpwalk, etc. These values previously adjusted by the port must now be specified in config.php. New installs will have this automatically, but existing installs must be updated manually. These are the entries you should add if upgrading from LibreNMS < 1.61: $config['snmpwalk'] = '/usr/local/bin/snmpwalk'; $config['snmpget'] = '/usr/local/bin/snmpget'; $config['snmpbulkwalk'] = '/usr/local/bin/snmpbulkwalk'; $config['snmptranslate'] = '/usr/local/bin/snmptranslate'; $config['ping'] = '/sbin/ping'; $config['mtr'] = '/usr/local/bin/mtr'; $config['nmap'] = '/usr/local/bin/nmap'; $config['nagios_plugins'] = '/usr/local/libexec/nagios'; $config['ipmitool'] = '/usr/local/bin/ipmitool'; $config['virsh'] = '/usr/local/bin/virsh'; $config['dot'] = '/usr/local/bin/dot'; $config['sfdp'] = '/usr/local/bin/sfdp'; $config['nfdump'] = '/usr/local/bin/nfdump';
Comment 4 Dries Michiels 2020-03-03 15:52:04 UTC
I like it! This completely reflects what I meant. Thank you for picking this up. Minor remark: In other/s/order to simplify (I think)
Comment 5 commit-hook 2020-03-03 16:26:02 UTC
A commit references this bug: Author: dvl Date: Tue Mar 3 16:25:34 UTC 2020 New revision: 527681 URL: https://svnweb.freebsd.org/changeset/ports/527681 Log: Update to 1.61 While here, adjust the webserver options (see PR) NOTE: upgrading existing installations will break unless you read UPGRADING and follow the instructions. In short: * Apache / mod_php is no longer an option * config.php needs entries added manually We are jumping a few versions here: * https://github.com/librenms/librenms/releases/tag/1.61 * https://github.com/librenms/librenms/releases/tag/1.60 * https://github.com/librenms/librenms/releases/tag/1.59 * https://github.com/librenms/librenms/releases/tag/1.58.1 * https://github.com/librenms/librenms/releases/tag/1.58 PR: 235949 Submitted by: Dries Michiels <email@example.com> Changes: head/UPDATING head/net-mgmt/librenms/Makefile head/net-mgmt/librenms/distinfo head/net-mgmt/librenms/files/patch-config.php.default head/net-mgmt/librenms/files/patch-includes_defaults.inc.php
Comment 6 Dan Langille 2020-03-03 16:27:26 UTC
Comment 7 Dries Michiels 2021-02-26 18:00:38 UTC
Hi Dan, With the most recent port revision bump you readded php_mod, this pulls in apache again. https://svnweb.freebsd.org/ports/head/net-mgmt/librenms/Makefile?revision=566568&view=markup Regards Dries
Comment 8 Dan Langille 2021-02-26 19:31:35 UTC
I'm sorry, that was not intended. I will fix this soon. My apologies.
Comment 9 Dan Langille 2021-02-26 19:44:03 UTC
Reverted via 566634
Comment 10 Dries Michiels 2021-02-26 19:46:03 UTC
Thanks! If you really want to add it as a dependency you can, you are the maintainer after all. Just wanted to let you now that we tried to get rid of apache and php_mod for exactly that reason in this PR. Thanks again. Dries
Comment 11 Dan Langille 2021-02-26 19:50:58 UTC
I had completely forgotten about mod_php requiring Apache. :)