[PC-BSD Pbi-dev] How to make a PBI with a combination of ports?

Ken Moore ken at pcbsd.org
Thu Feb 16 05:05:05 PST 2012

On 02/13/2012 12:53, Fabrizio Parrella wrote:
> Sorry if I am trying to suggest things even if I am kind of new on 9.0 
> and the new PBIs, but it seems to me that you need to add a custom 
> script when starting stopping apache as well as when you add the 
> configuration:
> something like (pseudocode):
>  - Add config to Apache/PHP httpd.conf  and to MySQL (create the new 
> user for phpMyAd)
>  - if Apache PBI exists, add same config changes to its httpd.conf
>  - if Apache PBI exists, do not start Apache/PHP PBI
> I would suggest to create a PBI with apache, mysql, php, phpMyAdmin, 
> and add the two simple "IF"
> Maybe even check if apache or mysql are installed with a simple:
>  - `which mysql`
>  - `which httpd`
> Fabry
> On 02/13/2012 12:40, Jeff wrote:
>> Thanks, I was able to build the PBI with Apache and PHP.
>> The problem now is that I wanted to include the same services scripts 
>> as found in the Apache PBI for start up and other stuff.  Plus I need 
>> a custom config file for phpmyadmin for initial setup, and want to 
>> modify httpd.conf with a script to include an alias for phpmyadmin.
>> No big deal, but it occurred to me that running the Apache PBI and 
>> PhpMyAdmin PBI that also includes Apache, would conflict unless I 
>> configure it to listen on a different port, which is a pain.
>> Right now, with the Apache PBI, you access the server at 
>> http://localhost/index.html, so another server running would have to 
>> be http://localhost:8080/phpmyadmin or something like that.
>> Is there another way to deal with that potential conflict?  What if 
>> the 2nd Apache installation used a virtual host setup - would that work?
>> If I want to include the services scripts and any other custom 
>> scripts, do I just add them in the pbi.conf?  I sort of concluded 
>> that by looking at pbi.conf for the Apache PBI.
>> Maybe it would just be easier to add PhpMyAdmin to the Apache PBI. It 
>> might make more sense anyway, to include PHP, and possibly even 
>> MySQL, since most people will want those too.
>> Just curious, if someone added PHP, etc to the Apache PBI 
>> environment, after the PBI was installed, what would happen to those 
>> additions when the PBI got updated?
>> Thanks,
>> Jeff

Just to follow up with this,

We have noticed a number of PBI requests come in for programs like 
phpmyadmin (phpvirtualbox, owncloud, etc...) that are just web services 
and not actual stand-alone programs. We are still discussing what the 
best course of action is for these.
Some of the options we have come up with are: Build the PBI with 
included web server and special configurations (as Fabry suggested), 
Warden inmates (programs to be used/run inside portjails with warden 
management), or package these programs with the main web servers but 
disabled by default (I.E. put phpvirtualbox with the Virtualbox PBI, 
phpmyadmin with the apache PBI, etc...)

In any case, for the time being it might be easier for you to just build 
those programs as ports for the moment. Since there is basically no 
binaries within those packages, there should not be a problem with them 
affecting other system components. Of course, putting them in a port 
jail is always more  secure... :-)

~~ Ken Moore ~~

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pcbsd.org/pipermail/pbi-dev/attachments/20120216/910beac3/attachment.html>

More information about the Pbi-dev mailing list