FreeBSD
Para instalar en FreeBSD, ejecute los siguientes comandos en la terminal:
Instalación
Instale FFmpeg:
sudo pkg update
sudo pkg install ffmpeg
Instale Yucca:
- Yucca Free
- Yucca Plus / Enterprise
- AMD64
- ARM64
- ARM
sudo mkdir -p /opt/yucca/ffmpeg
cd /opt/yucca
YUCCA_VER=$(fetch -qo - https://releases.yucca.app/latest/VERSION.txt)
sudo fetch https://releases.yucca.app/latest/yucca_freebsd_amd64.tar.gz
sudo fetch https://releases.yucca.app/latest/yucca_${YUCCA_VER}_checksums.txt
sha256 -c yucca_${YUCCA_VER}_checksums.txt --ignore-missing
sudo tar -xzvf yucca_freebsd_amd64.tar.gz
sudo rm -f yucca_freebsd_amd64.tar.gz yucca_${YUCCA_VER}_checksums.txt
sudo mkdir -p /opt/yucca/ffmpeg
cd /opt/yucca
YUCCA_VER=$(fetch -qo - https://releases.yucca.app/latest/VERSION.txt)
sudo fetch https://releases.yucca.app/latest/yucca_freebsd_arm64.tar.gz
sudo fetch https://releases.yucca.app/latest/yucca_${YUCCA_VER}_checksums.txt
sha256 -c yucca_${YUCCA_VER}_checksums.txt --ignore-missing
sudo tar -xzvf yucca_freebsd_arm64.tar.gz
sudo rm -f yucca_freebsd_arm64.tar.gz yucca_${YUCCA_VER}_checksums.txt
sudo mkdir -p /opt/yucca/ffmpeg
cd /opt/yucca
YUCCA_VER=$(fetch -qo - https://releases.yucca.app/latest/VERSION.txt)
sudo fetch https://releases.yucca.app/latest/yucca_freebsd_arm.tar.gz
sudo fetch https://releases.yucca.app/latest/yucca_${YUCCA_VER}_checksums.txt
sha256 -c yucca_${YUCCA_VER}_checksums.txt --ignore-missing
sudo tar -xzvf yucca_freebsd_arm.tar.gz
sudo rm -f yucca_freebsd_arm.tar.gz yucca_${YUCCA_VER}_checksums.txt
- AMD64
- ARM64
- ARM
sudo mkdir -p /opt/yucca/ffmpeg
cd /opt/yucca
YUCCA_VER=$(fetch -qo - https://releases.yucca.app/latest/VERSION.txt)
sudo fetch https://releases.yucca.app/latest/yucca-ent_freebsd_amd64.tar.gz
sudo fetch https://releases.yucca.app/latest/yucca_${YUCCA_VER}_checksums.txt
sha256 -c yucca_${YUCCA_VER}_checksums.txt --ignore-missing
sudo tar -xzvf yucca-ent_freebsd_amd64.tar.gz
sudo rm -f yucca-ent_freebsd_amd64.tar.gz yucca_${YUCCA_VER}_checksums.txt
sudo mkdir -p /opt/yucca/ffmpeg
cd /opt/yucca
YUCCA_VER=$(fetch -qo - https://releases.yucca.app/latest/VERSION.txt)
sudo fetch https://releases.yucca.app/latest/yucca-ent_freebsd_arm64.tar.gz
sudo fetch https://releases.yucca.app/latest/yucca_${YUCCA_VER}_checksums.txt
sha256 -c yucca_${YUCCA_VER}_checksums.txt --ignore-missing
sudo tar -xzvf yucca-ent_freebsd_arm64.tar.gz
sudo rm -f yucca-ent_freebsd_arm64.tar.gz yucca_${YUCCA_VER}_checksums.txt
sudo mkdir -p /opt/yucca/ffmpeg
cd /opt/yucca
YUCCA_VER=$(fetch -qo - https://releases.yucca.app/latest/VERSION.txt)
sudo fetch https://releases.yucca.app/latest/yucca-ent_freebsd_arm.tar.gz
sudo fetch https://releases.yucca.app/latest/yucca_${YUCCA_VER}_checksums.txt
sha256 -c yucca_${YUCCA_VER}_checksums.txt --ignore-missing
sudo tar -xzvf yucca-ent_freebsd_arm.tar.gz
sudo rm -f yucca-ent_freebsd_arm.tar.gz yucca_${YUCCA_VER}_checksums.txt
Genere el archivo de configuración con los valores predeterminados:
sudo /opt/yucca/yucca server --config emtpy --show-config | sed 's|data_dir = ""|data_dir = "/opt/yucca/data"|' > /opt/yucca/yucca.toml
Cree el usuario y establezca el propietario y los permisos:
sudo pw groupadd yucca -g 642
sudo pw useradd yucca -u 642 -g yucca -s /sbin/nologin -d /opt/yucca -c "Yucca Service User"
sudo chown -R yucca:yucca /opt/yucca
sudo chmod -R 2775 /opt/yucca
Autoarranque
- Cree un archivo llamado
yuccasin extensión en el directorio/usr/local/etc/rc.d/. - Copie el código del script de inicialización en ese archivo.
#!/bin/sh
# PROVIDE: yucca
# REQUIRE: LOGIN
# KEYWORD: shutdown
. /etc/rc.subr
name="yucca"
rcvar="yucca_enable"
load_rc_config $name
: ${yucca_enable:=no}
: ${yucca_pidfile="/var/run/yucca.pid"}
: ${yucca_user="yucca"}
: ${yucca_group="yucca"}
: ${yucca_logfile="/var/log/yucca.log"}
: ${yucca_command="/opt/yucca/yucca server --config /opt/yucca/yucca.toml"}
command="/opt/yucca/yucca"
command_args="server --config /opt/yucca/yucca.toml"
pidfile="/var/run/yucca.pid"
logfile="/var/log/yucca.log"
start_cmd="${name}_start"
stop_cmd="${name}_stop"
status_cmd="${name}_status"
yucca_start() {
echo "Starting $name."
if [ ! -f $pidfile ]; then
su $yucca_user -c "$yucca_command >> $yucca_logfile 2>&1 & echo \$! > $yucca_pidfile"
echo "$name started."
else
echo "$name is already running."
fi
}
yucca_stop() {
echo "Stopping $name."
if [ -f $pidfile ]; then
kill -TERM `cat $pidfile`
rm -f $pidfile
echo "$name stopped."
else
echo "$name is not running."
fi
}
yucca_status() {
if [ -f $pidfile ]; then
echo "$name is running."
else
echo "$name is not running."
fi
}
run_rc_command "$1"
- Asegúrese de que el script tenga permisos de ejecución con el comando
chmod +x /usr/local/etc/rc.d/yucca. - Cree los directorios y archivos necesarios para los registros y el archivo PID. Por ejemplo:
mkdir -p /var/log
touch /var/log/yucca.log
chown yucca:yucca /var/log/yucca.log
touch /var/run/yucca.pid
chown yucca:yucca /var/run/yucca.pid
Añada yucca_enable="YES" al archivo /etc/rc.conf para indicar que el servicio yucca debe iniciarse al arrancar el sistema.
Ahora puede gestionar el servicio con los siguientes comandos:
service yucca start— Inicia el servicio.service yucca stop— Detiene el servicio.service yucca restart— Reinicia el servicio.service yucca status— Comprueba el estado del servicio.
Comprobación del funcionamiento
Tras la instalación y el arranque, la interfaz web estará disponible en http://ip-de-su-servidor:9910. Si la interfaz no está disponible tras la instalación, compruebe el estado del servicio y revise los registros del servidor.
Actualización
Descargue el archivo más reciente (vea la sección «Instalación» más arriba), extráigalo sobre el directorio /opt/yucca y reinicie el servicio:
sudo service yucca restart
Desinstalación
sudo service yucca stop
sudo rm -rf /opt/yucca /usr/local/etc/rc.d/yucca
sudo pw userdel yucca
sudo pw groupdel yucca