Installing Software.
A new jail contains the base system from its selected FreeBSD release. Install and manage additional software from the jail shell, not from the FreeCORE host shell.
Go to Jails, expand the jail, and click Start. After its state changes to up, click Shell.
Install Binary Packages
Section titled “Install Binary Packages”Binary packages are the simplest way to add software. Use pkg search to find a package, pkg install to install it, and pkg upgrade to update installed packages:
pkg updatepkg search <name>pkg install <package-name>pkg upgradeUse pkg info to list installed packages or pkg info <package-name> to inspect one package. Third-party programs normally install under /usr/local; their configuration files are usually under /usr/local/etc.
Build from the Ports Collection
Section titled “Build from the Ports Collection”Use a port only when you need build-time options or software that is not available as a package. Building ports consumes more CPU, memory, storage, and time than installing packages.
The Ports Collection is maintained with Git. Follow the FreeBSD Handbook: Using the Ports Collection and select a ports branch compatible with the package repository used inside the jail. Mixing packages from one branch with ports from another can create dependency conflicts.
A typical first checkout is:
pkg install gitgit clone --depth 1 --branch <quarterly-branch> \ https://git.FreeBSD.org/ports.git /usr/portsUpdate an existing checkout with:
git -C /usr/ports pullThen enter the desired port directory and build it:
cd /usr/ports/<category>/<port>make configmake install cleanRead /usr/ports/UPDATING before upgrading software built from ports.
Start an Installed Service
Section titled “Start an Installed Service”Packages that provide a service normally install an rc script under /usr/local/etc/rc.d. Replace <service> below with the rc script name:
sysrc <service>_enable=YESservice <service> startservice <service> statusUse service <service> onestart to test a service without enabling it at jail startup. Consult the package documentation for any required configuration under /usr/local/etc before starting it.
Previous
Bastille Jails