1
0
Fork 0
mirror of https://github.com/morpheus65535/bazarr synced 2025-01-05 06:22:35 +00:00

Created Installation-FreeBSD (markdown)

morpheus65535 2019-02-02 23:05:24 -05:00
parent bd934797ad
commit 28af87a69e

46
Installation-FreeBSD.md Normal file

@ -0,0 +1,46 @@
Instruction as provided by @Derkades:
Disclaimer: I don't know how rc.d works so the script is pretty crappy and doesn't have start/stop/status functionality. It only starts the program on startup, which was enough for me.
# Installing Bazarr on FreeBSD
* Install the required software `pkg update && pkg install git python27 py27-pip py27-libxml2 py27-libxslt py27-sqlite3`
* `cd /usr/local`
* Clone the repository using `git clone https://github.com/morpheus65535/bazarr.git` (this will download the files to `/usr/local/bazarr`)
* `cd bazarr`
* Install Python requirements using `pip install -r requirements.txt`
* Check if it works `python2.7 bazarr.py`. You should see `BAZARR is started and waiting for request on http://0.0.0.0:6767/`
## Starting on boot
* `nano /usr/local/etc/rc.d/bazarr`
* Enter this:
```
#!/bin/sh
#
# PROVIDE: bazarr
# REQUIRE: networking
# KEYWORD:
. /etc/rc.subr
name="bazarr"
rcvar="bazarr_enable"
command="/usr/local/bin/python2.7 /usr/local/bazarr/bazarr.py"
bazarr_user=root
start_cmd="bazarr_start"
bazarr_start(){
/usr/sbin/daemon -r -f -u $bazarr_user $command
}
load_rc_config $name
: ${bazarr_enable:=no}
run_rc_command "$1"
```
* Save and exit (ctrl+x -> y -> enter)
* Make the file executable `chmod +x /usr/local/etc/rc.d/bazarr`
* `nano /etc/rc.conf`
* On the last line, add bazarr_enable="YES"
* Reboot