Solved Configure port with only the wanted options

As I needed databases/luadbi to have support for PostgreSQL and not for MySQL, as the default config, and I didn't want to do this in the server, I've configured a jail in my workstation to configure the port.

After building it, that port as well as some other dependencies are available at /var/ports/sharedfs/usr/ports.

Code:
>ls
databases       devel           lang            ports-mgmt      print

For each, there's a stage directory where all the files to be installed were saved, for example:

Code:
>ls databases/postgresql13-client/work/stage/usr/local

bin     etc     include lib     libdata libexec man     sbin    share   tests   www

I know that there's poudriere, but it seems overkill for my setup.

From here, what is the suggested way to install these files?

Do a tar -f and untar at the server?

Add some elements to that tarball, compressed as xz so that it can be installed as a package and registered?

Other way?
 
after build
make package
scp thepackage totarget
pkg add package
Just the wrong way to do that!
Code:
# cd /usr/ports/databases/luadbi
# make config <--- this is where you enable all the options you need!
# make <--- compile with options you set
# make package
# (Find your package on the filesystem, fish it out of jail, install it)

Poudriere is an unwieldy beast, but set up right, can be used for your case very nicely. It was in fact designed for such use cases.
 
Just the wrong way to do that!
Actually it's not. If you read more careful then OP wants to avoid building this stuff on the server. Ergo: building packages and then installing those on the server is the right way to go.

And well, package is a perfectly valid build target, just see ports(7).
 
After building it, that port as well as some other dependencies
make package
Execute make package-recursive in the primary ports directory to include packaging the dependencies as well instead of running the "package" target separately for each port.

Before making packages define a packages directory with PACKAGES variable in /etc/make.conf of the jail, to collect all the packages in one place (see ports(7)).

From the mounted shared file system (/var/ports/sharedfs/usr/ports) use, as already mentioned, pkg-add(8) to install.

Or if this is a permanent use case, building packages on the workstation for the server, define the mounted file system as a repository in the servers /usr/local/etc/pkg/repos/workstation.conf pkg.conf(5) and pkg-install(8) -r.
 
Actually it's not. If you read more careful then OP wants to avoid building this stuff on the server. Ergo: building packages and then installing those on the server is the right way to go.

And well, package is a perfectly valid build target, just see ports(7).
Yeah, my omission here was that I didn't specify that the steps are being done inside a jail, rather than straight on the server. But I do see the logic. ?
 
Back
Top