-
Notifications
You must be signed in to change notification settings - Fork 246
Setting up a pfSense package build environment
The following procedures outline the steps required to build and configure a pfSense 2.3 package building system. It is assumed the reader is comfortable with virtualization software, networking configuration and the *nix command line.
Unless you are running a FreeBSD 10.3 OS as your host system, you will have to download and configure a virtual environment. I chose to use VirtualBox virtualizer software for this project because it is freely available as Open Source Software.
Once you have downloaded and installed the appropriate binaries for your host system, the fastest approach is to create a new FreeBSD guest virtual machine with an .vhd image. The VM image for FreeBSD 10.3-RELEASE can be downloaded here. Download and unpack the image to a suitable location. When creating a new BSD VM, during the storage setup stage, rather than creating a new disk image, select the downloaded file FreeBSD-10.3-RELEASE-amd64.vhd. Before starting the new VM, you may want to configure the network adapter. I set mine to bridge to the host machine physical adapter, but you may want to do things differently depending on your network environment.
##Configure the Guest OS
When you first boot in the VirtualBox console window, you can log in as root
(password-less). You can set a password using the passwd
command. The system at this point is bare-bones, you will not have a network connection or even a hostname configured. Add the following to the /etc/rc.conf
file:
ifconfig_em0="DHCP"
sshd_enable="YES"
hostname="bsd-builder"
To be able to ssh into your guest VM, you will need to allow root login (for the security conscious, you may want to set this up differently) by editing the /etc/ssh/sshd_config
file and adding the line PermitRootLogin yes
. At this point you can reboot and you should have ssh access to your FreeBSD guest system.
##Building Packages Required reading:
- https://doc.pfsense.org/index.php/Developing_Packages
- https://doc.pfsense.org/index.php/Package_Port_Directory_Structure
- https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/ports.html
To be continued...