mirror of
https://github.com/YunoHost-Apps/streama_ynh.git
synced 2024-09-03 20:26:30 +02:00
update add service
This commit is contained in:
parent
5308375957
commit
ee490c2677
2 changed files with 31 additions and 7 deletions
16
conf/streama.service
Normal file
16
conf/streama.service
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
[Unit]
|
||||||
|
Description=streama
|
||||||
|
After=network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
WorkingDirectory=/opt/streama/
|
||||||
|
User=admin
|
||||||
|
Group=users
|
||||||
|
Type=simple
|
||||||
|
UMask=000
|
||||||
|
ExecStart=/usr/bin/java -Djava.awt.headless=true -jar streama-1.6.0-RC9.war
|
||||||
|
RestartSec=15
|
||||||
|
Restart=always
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
|
@ -76,17 +76,26 @@ ynh_app_setting_set $app is_public $is_public
|
||||||
### - Remove the section "CLOSE A PORT" in the remove script
|
### - Remove the section "CLOSE A PORT" in the remove script
|
||||||
|
|
||||||
# Find a free port
|
# Find a free port
|
||||||
port=$(ynh_find_port 8096)
|
port=$(ynh_find_port 8080)
|
||||||
# Open this port
|
# Open this port
|
||||||
yunohost firewall allow --no-upnp TCP $port 2>&1
|
yunohost firewall allow --no-upnp TCP $port 2>&1
|
||||||
ynh_app_setting_set $app port $port
|
ynh_app_setting_set $app port $port
|
||||||
|
|
||||||
#==============================================
|
#==============================================
|
||||||
# INSTALL EMBY
|
# INSTALL JAVA
|
||||||
#==============================================
|
#==============================================
|
||||||
|
|
||||||
wget --no-verbose 'https://github.com/MediaBrowser/Emby.Releases/releases/download/3.5.3.0/emby-server-deb_3.5.3.0_amd64.deb'
|
ynh_package_install openjdk-8-jre-headless
|
||||||
dpkg --install emby-server-deb_3.5.3.0_amd64.deb
|
|
||||||
|
#==============================================
|
||||||
|
# INSTALL STREAMA
|
||||||
|
#==============================================
|
||||||
|
|
||||||
|
mkdir /opt/streama
|
||||||
|
#mkdir /var/www/$path_url
|
||||||
|
wget https://github.com/streamaserver/streama/releases/download/v1.6.0-RC9/streama-1.6.0-RC9.war
|
||||||
|
mv streama-1.6.0-RC9.war /opt/streama
|
||||||
|
chmod +x /opt/streama/streama-1.6.0-RC9.war
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# NGINX CONFIGURATION
|
# NGINX CONFIGURATION
|
||||||
|
@ -105,9 +114,8 @@ ynh_system_user_create $app
|
||||||
#=================================================
|
#=================================================
|
||||||
# MODIFY A CONFIG FILE
|
# MODIFY A CONFIG FILE
|
||||||
#=================================================
|
#=================================================
|
||||||
#cp -a ../conf/onlyoffice-documentserver.conf /etc/onlyoffice/documentserver/nginx/onlyoffice-documentserver.conf
|
|
||||||
#ynh_replace_string "__NEXTCLOUDDOMAIN__" "$nextcloud_domain" "/etc/loolwsd/loolwsd.xml"
|
cp -a ../conf/streama.service /etc/systemd/system/streama.service
|
||||||
#ynh_replace_string "__PASSWORD__" "$password" "/etc/loolwsd/loolwsd.xml"
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# STORE THE CONFIG FILE CHECKSUM
|
# STORE THE CONFIG FILE CHECKSUM
|
||||||
|
|
Loading…
Add table
Reference in a new issue