Scripted installation of Plex Media Server

This is copy/paste overkill but the output is instructive:

root@pms:~ # pkg install plexmediaserver
The package management tool is not yet installed on your system.
Do you want to fetch and install it now? [y/N]: y
Bootstrapping pkg from pkg+http://pkg.FreeBSD.org/FreeBSD:11:amd64/latest, please wait…
Verifying signature with trusted certificate pkg.freebsd.org.2013102301… done
[pms] Installing pkg-1.14.6…
[pms] Extracting pkg-1.14.6: 100%
Updating FreeBSD repository catalogue…
[pms] Fetching meta.conf: 100% 163 B 0.2kB/s 00:01
[pms] Fetching packagesite.txz: 100% 6 MiB 627.5kB/s 00:10
[pms] Extracting pkg-1.14.6: 100%
Updating FreeBSD repository catalogue…
[pms] Fetching meta.conf: 100% 163 B 0.2kB/s 00:01
[pms] Fetching packagesite.txz: 100% 6 MiB 627.5kB/s 00:10
Processing entries: 100%
FreeBSD repository update completed. 30836 packages processed.
All repositories are up to date.
Updating database digests format: 100%
The following 1 package(s) will be affected (of 0 checked):
New packages to be INSTALLED:
plexmediaserver: 1.19.4.2935
Number of packages to be installed: 1
The process will require 367 MiB more space.
96 MiB to be downloaded.
Proceed with this action? [y/N]: y
[pms] [1/1] Fetching plexmediaserver-1.19.4.2935.txz: 100% 96 MiB 685.4kB/s 02:27
Checking integrity… done (0 conflicting)
[pms] [1/1] Installing plexmediaserver-1.19.4.2935…
===> Creating groups.
Creating group ‘plex’ with gid ‘972’.
===> Creating users
Creating user ‘plex’ with uid ‘972’.
[pms] [1/1] Extracting plexmediaserver-1.19.4.2935: 100%
=====
Message from plexmediaserver-1.19.4.2935:

multimedia/plexmediaserver includes an RC script:
/usr/local/etc/rc.d/plexmediaserver
TO START PLEXMEDIASERVER ON BOOT:
sysrc plexmediaserver_enable=YES
START MANUALLY:
service plexmediaserver start
Once started, visit the following to configure:
http://localhost:32400/web
@@@ INTEL GPU OFFLOAD NOTES @@@
If you have a supported Intel GPU, you can leverage hardware
accelerated encoding/decoding in Plex Media Server on FreeBSD 12.0+.
The requirements are as follows:
* Install multimedia/drm-kmod: e.g., pkg install drm-fbsd12.0-kmod
* Enable loading of kernel module on boot: sysrc kld_list+=“i915kms”
** If Plex will run in a jail, you must load the module outside the jail!
* Load the kernel module now (although reboot is advised): kldload i915kms
* Add plex user to the video group: pw groupmod -n video -m plex
* For jails, make a devfs ruleset to expose /dev/dri/* devices.
e.g., /dev/devfs.rules on the host:
[plex_drm=10]
add include $devfsrules_hide_all
add include $devfsrules_unhide_basic
add include $devfsrules_unhide_login
add include $devfsrules_jail
add path ‘dri*’ unhide
add path ‘dri/’ unhide
add path 'drm
’ unhide
add path ‘drm/*’ unhide
* Enable the devfs ruleset for your jail. e.g., devfs_ruleset=10 in your
/etc/jail.conf or for iocage, iocage set devfs_ruleset=“10”
Please refer to documentation for all other FreeBSD jail management utilities.
* Make sure hardware transcoding is enabled in the server settings
@@@ INTEL GPU OFFLOAD NOTES @@@
root@pms:~ #

Well that looks better. Now I try and start plex:

root@pms:~ # service plexmediaserver start
Cannot ‘start’ plexmediaserver. Set plexmediaserver_enable to YES in /etc/rc.conf or use ‘onestart’ instead of ‘start’.
root@pms:~ # service plexmediaserver onestart
Starting plexmediaserver.
root@pms:~ # service plexmediaserver status
Cannot ‘status’ plexmediaserver. Set plexmediaserver_enable to YES in /etc/rc.conf or use ‘onestatus’ instead of ‘status’.
root@pms:~ # service plexmediaserver onestatus
plexmediaserver is not running.
root@pms:~ #

I am not yet out of the woods and into the Movies yet. I will spend some time tinkering later today.

Thanks.