Skip to content

Instantly share code, notes, and snippets.

@ohmantics
Last active August 8, 2022 01:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ohmantics/7983223a3a5598cd8087473e67ab15dd to your computer and use it in GitHub Desktop.
Save ohmantics/7983223a3a5598cd8087473e67ab15dd to your computer and use it in GitHub Desktop.
Setup owntone in an iocage jail
sudo iocage create -n "owntone" -r 12.3-RELEASE dhcp=1 bpf=1 vnet=1 allow_raw_sockets="1"
sudo mkdir -p /mnt/tank/apps/owntone
sudo chown media:media /mnt/tank/apps/owntone
sudo iocage start owntone
#sudo iocage console owntone
sudo iocage exec owntone "mkdir -p /mnt/media"
sudo iocage fstab -a owntone /mnt/tank/media /mnt/media nullfs rw 0 0
sudo iocage exec owntone "mkdir -p /config"
sudo iocage fstab -a owntone /mnt/tank/apps/owntone /config nullfs rw 0 0
sudo iocage exec owntone "pw user add media -c media -u 8675309 -d /nonexistent -s /usr/bin/nologin"
sudo iocage exec owntone "pw groupadd -n media -g 8675309"
sudo iocage exec owntone "pkg update && pkg upgrade"
# edit freebsd_install.sh to change USERNAME and USERGROUP to media, sysconfdir to /config
sudo iocage exec owntone "/root/owntone-server/scripts/freebsd_install.sh"
# edit /etc/crontab to add MAILTO=""
# edit /config/owntone.conf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment