mirror of
https://github.com/tschettervictor/bsd-apps.git
synced 2025-12-14 19:10:03 +01:00
Update mediamtx-install.sh - fix config file location
This commit is contained in:
@@ -15,7 +15,7 @@ git-lite \
|
|||||||
go${GO_VERSION}
|
go${GO_VERSION}
|
||||||
|
|
||||||
# Create Directories
|
# Create Directories
|
||||||
mkdir -p /usr/local/www/mediamtx
|
mkdir -p /usr/local/etc/mediamtx
|
||||||
mkdir -p /usr/local/etc/rc.d
|
mkdir -p /usr/local/etc/rc.d
|
||||||
|
|
||||||
# MediaMTX Setup
|
# MediaMTX Setup
|
||||||
@@ -24,17 +24,17 @@ cd /mediamtx && go122 generate ./...
|
|||||||
cd /mediamtx && go122 build .
|
cd /mediamtx && go122 build .
|
||||||
cp /mediamtx/mediamtx /usr/local/bin/mediamtx
|
cp /mediamtx/mediamtx /usr/local/bin/mediamtx
|
||||||
chmod +x /usr/local/bin/mediamtx
|
chmod +x /usr/local/bin/mediamtx
|
||||||
if ! [ -f "/usr/local/www/mediamtx/mediamtx.yml" ]; then
|
if [ ! -f "/usr/local/etc/mediamtx/mediamtx.yml" ]; then
|
||||||
cp /mediamtx/mediamtx.yml /usr/local/www/mediamtx/
|
cp /mediamtx/mediamtx.yml /usr/local/etc/mediamtx/
|
||||||
fi
|
fi
|
||||||
rm -R /mediamtx
|
rm -R /mediamtx
|
||||||
fetch -o /usr/local/etc/rc.d/mediamtx https://raw.githubusercontent.com/tschettervictor/bsd-apps/main/mediamtx/includes/mediamtx
|
fetch -o /usr/local/etc/rc.d/mediamtx https://raw.githubusercontent.com/tschettervictor/bsd-apps/main/mediamtx/includes/mediamtx
|
||||||
chmod +x /usr/local/etc/rc.d/mediamtx
|
chmod +x /usr/local/etc/rc.d/mediamtx
|
||||||
pw user add mediamtx -c mediamtx -u 1935 -d /nonexistent -s /usr/bin/nologin
|
pw user add mediamtx -c mediamtx -u 1935 -d /nonexistent -s /usr/bin/nologin
|
||||||
chown -R mediamtx:mediamtx /usr/local/www/mediamtx
|
chown -R mediamtx:mediamtx /usr/local/etc/mediamtx
|
||||||
|
|
||||||
# Enable and Start Services
|
# Enable and Start Services
|
||||||
sysrc mediamtx_config="/usr/local/www/mediamtx/mediamtx.yml"
|
sysrc mediamtx_config="/usr/local/etc/mediamtx/mediamtx.yml"
|
||||||
sysrc mediamtx_enable="YES"
|
sysrc mediamtx_enable="YES"
|
||||||
service mediamtx start
|
service mediamtx start
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user