Manual deluge installation - problem with rc file?

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,458
Trying to manually install Deluge in a jail--the plugin isn't installing and is giving an absolutely useless error message. So I create the jail and add mountpoints with:
Code:
iocage create --name "deluge" -r 11.2-RELEASE ip4_addr="vnet0|192.168.1.67/24" defaultrouter="192.168.1.1" boot="on" host_hostname="deluge" vnet="on"
iocage fstab -a deluge /mnt/tank/portsnap/ports /usr/ports nullfs rw 0 0
iocage fstab -a deluge /mnt/tank/portsnap/db /var/db/portsnap nullfs rw 0 0
iocage fstab -a deluge /mnt/tank/apps/deluge /config nullfs rw 0 0
iocage fstab -a deluge /mnt/tank/torrents /media/torrents nullfs rw 0 0

Enter the jail, add a user of media with uid/gid of 8675309, login disabled, home directory of /nonexistent, then pkg install nano deluge-cli. Once it's installed:
Code:
chown -R media:media /config
sysrc deluged_enable=YES
sysrc deluged_user=media
sysrc deluged_group=media
sysrc deluged_confdir=/config
sysrc deluge_web_enable=YES
sysrc deluge_web_user=media
sysrc deluge_web_group=media
sysrc deluge_web_confdir=/config

The deluged service starts just fine, but deluge_web doesn't:
Code:
root@deluge:/usr/local/etc/rc.d # service deluge_web start
/usr/local/etc/rc.d/deluge_web: 67: Syntax error: "}" unexpected (expecting "fi")

...and indeed, when I look in the rc file, there seems to be a missing "fi":
1555762666830.png

That's easy enough to fix. More problematic is that it insists on putting files into the user's home directory, even when deluge_web_confdir is pointing somewhere else. And since media has a home directory of /nonexistent, it fails. A simple short-term fix would be to give media a home directory, but it doesn't seem like this should be necessary. Thoughts?
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,458
Looks like that has been since fixed upstream
Well, the first problem has. But since it's easy enough to give the user a home directory, a step in the right direction.
 

shiphtfour

Dabbler
Joined
Jan 21, 2013
Messages
26
Sorry for rehashing an old thread and for the noob question, but is there a guide anywhere for setting up the separate datasets for portsnap/ports, portsnap/db, and apps/deluge?
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,458
is there a guide anywhere for setting up the separate datasets for portsnap/ports, portsnap/db, and apps/deluge?
I don't think there is a guide other than the manual--creating datasets is pretty simple. The datasets I used are just portsnap and apps; /ports, /db, and /deluge are just subdirectories in those datasets. I don't really remember why I mounted the portsnap dataset to the jail, though; I didn't use ports at all.
 

shiphtfour

Dabbler
Joined
Jan 21, 2013
Messages
26
I don't think there is a guide other than the manual--creating datasets is pretty simple. The datasets I used are just portsnap and apps; /ports, /db, and /deluge are just subdirectories in those datasets. I don't really remember why I mounted the portsnap dataset to the jail, though; I didn't use ports at all.
Thanks for the reply. A better question would have been what is contained in these datasets and what is the shell command for downloading it? If my understanding is correct, it looks like the apps/deluge dataset contains the config files for the deluge jail. I noticed that this guide uses the same approach, but does not go into detail about how to create them and what each dataset needs to contain for a first-time installation of each app in a new jail.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,458
Nothing needs to be there before installation. The portsnap dataset would contain the FreeBSD ports library, which isn't really required for this installation (as I said, I don't honestly remember why I used it). The apps/deluge directory contains the config files, which deluge itself will put there--you just need to create those directories (they don't even have to be datasets).
 
Top