mirror of
https://github.com/YunoHost-Apps/mumbleserver_ynh.git
synced 2024-09-03 19:46:03 +02:00
[mod] install: install with 'apt', modify conf file then move it.
This commit is contained in:
parent
ca69b2971f
commit
fd570fa59f
1 changed files with 10 additions and 9 deletions
|
@ -31,9 +31,16 @@ fi
|
||||||
# Save app settings
|
# Save app settings
|
||||||
ynh_app_setting_set $app port "$port"
|
ynh_app_setting_set $app port "$port"
|
||||||
|
|
||||||
# install via apt-get
|
# Install Mumble Debian package via apt
|
||||||
sudo apt-get update > /dev/null 2>&1
|
sudo apt update > /dev/null 2>&1
|
||||||
sudo apt-get install -y mumble-server > /dev/null 2>&1
|
sudo apt install -y mumble-server > /dev/null 2>&1
|
||||||
|
|
||||||
|
# Configuring with given settings
|
||||||
|
mumble_conf="../conf/mumble-server.ini"
|
||||||
|
sudo sed -i "s/welcometext=.*/welcometext=$welcometext/g" $mumble_conf
|
||||||
|
sudo sed -i "s/port=.*/port=$port/g" $mumble_conf
|
||||||
|
sudo sed -i "s/serverpassword=.*/serverpassword=$server_password/g" $mumble_conf
|
||||||
|
sudo sed -i "s/#registerName=.*/registerName=$registerName/g" $mumble_conf
|
||||||
|
|
||||||
# Copying conf file
|
# Copying conf file
|
||||||
mumble_conf="/etc/mumble-server.ini"
|
mumble_conf="/etc/mumble-server.ini"
|
||||||
|
@ -41,12 +48,6 @@ sudo cp ../conf/mumble-server.ini $mumble_conf
|
||||||
sudo chmod 660 $mumble_conf
|
sudo chmod 660 $mumble_conf
|
||||||
sudo chown :mumble-server $mumble_conf
|
sudo chown :mumble-server $mumble_conf
|
||||||
|
|
||||||
#configuring with given settings
|
|
||||||
sudo sed -i "s/welcometext=.*/welcometext=$welcometext/g" $mumble_conf
|
|
||||||
sudo sed -i "s/port=.*/port=$port/g" $mumble_conf
|
|
||||||
sudo sed -i "s/serverpassword=.*/serverpassword=$server_password/g" $mumble_conf
|
|
||||||
sudo sed -i "s/#registerName=.*/registerName=$registerName/g" $mumble_conf
|
|
||||||
|
|
||||||
#open port in firewall
|
#open port in firewall
|
||||||
sudo yunohost firewall allow Both $port > /dev/null 2>&1
|
sudo yunohost firewall allow Both $port > /dev/null 2>&1
|
||||||
sudo yunohost firewall allow --ipv6 Both $port > /dev/null 2>&1
|
sudo yunohost firewall allow --ipv6 Both $port > /dev/null 2>&1
|
||||||
|
|
Loading…
Add table
Reference in a new issue