mirror of
https://github.com/YunoHost-Apps/jitsi_ynh.git
synced 2024-09-03 19:35:57 +02:00
Merge pull request #71 from YunoHost-Apps/testing
add max memory for vm configuration (#70)
This commit is contained in:
commit
63248b3407
12 changed files with 128 additions and 3 deletions
|
@ -18,7 +18,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in
|
|||
Jitsi Meet is a libre software (Apache) WebRTC JavaScript app that uses Jitsi Videobridge to provide high quality, secure, and scalable video conferences.
|
||||
|
||||
|
||||
**Shipped version:** 1.0.5913~ynh1
|
||||
**Shipped version:** 1.0.5913~ynh2
|
||||
|
||||
**Demo:** https://meet.jit.si/
|
||||
|
||||
|
@ -34,6 +34,7 @@ Jitsi Meet is a libre software (Apache) WebRTC JavaScript app that uses Jitsi Vi
|
|||
2. **Jitsi** requires the ports TCP/4443 and UDP/10000 to be forwarded to your YunoHost (The same way you forwarded 80 (HTTP), 443 (HTTPS), etc... https://yunohost.org/#/isp_box_config)
|
||||
3. **Jitsi** will stop and disable Metronome XMPP.
|
||||
4. LDAP authentication is activated, only authenticated users to create new conference rooms. Whenever a new room is about to be created, Jitsi Meet will prompt for a user name and password. After the room is created, others will be able to join from anonymous domain.
|
||||
5. **Jitsi** is configured for 50 users maximum, this number can be increase going to the Yunohost config panel
|
||||
|
||||
## Documentation and resources
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour
|
|||
Jitsi Meet est un logiciel libre (Apache) dont Jitsi Videobridge, avec WebRTC Javascript, propose des vidéos-conférences de haute qualité, sécurisées et évolutives.
|
||||
|
||||
|
||||
**Version incluse :** 1.0.5913~ynh1
|
||||
**Version incluse :** 1.0.5913~ynh2
|
||||
|
||||
**Démo :** https://meet.jit.si/
|
||||
|
||||
|
@ -30,6 +30,7 @@ Jitsi Meet est un logiciel libre (Apache) dont Jitsi Videobridge, avec WebRTC Ja
|
|||
2. **Jitsi** demande que les ports TCP/4443 et UDP/10000 soient routés vers votre YunoHost (De la même manière que le sont les ports 80 (HTTP), 443 (HTTPS), etc... https://yunohost.org/#/isp_box_config)
|
||||
3. **Jitsi** va arréter et désactiver le service XMPP Metronome.
|
||||
4. L'authentification LDAP est activée, seuls les utilisateurs authentifiés peuvent créer de nouvelles salles de conférence. Chaque fois qu'une nouvelle salle est sur le point d'être créée, Jitsi Meet vous demandera un nom d'utilisateur et un mot de passe. Une fois la salle créée, d'autres personnes pourront la rejoindre à partir d'un domaine anonyme.
|
||||
5. **Jitsi** est configuré pour 50 utilisateurs maximum, ce nombre peut être augmenté en allant dans le panneau de configuration Yunohost
|
||||
|
||||
## Documentations et ressources
|
||||
|
||||
|
|
|
@ -13,6 +13,8 @@
|
|||
upgrade=1 from_commit=f967b101803c49655e460bdb2c1b0fb73320d0e3
|
||||
# 1.0.4466~ynh2
|
||||
upgrade=1 from_commit=ba635a58f8184b5dd4a6682b8da96909d3d31060
|
||||
# 1.0.5913~ynh1
|
||||
upgrade=1 from_commit=12d4758ea7582c9d15d0bd80e2eb5f03ccac8484
|
||||
backup_restore=1
|
||||
multi_instance=0
|
||||
port_already_use=0
|
||||
|
|
|
@ -17,5 +17,8 @@ JICOFO_AUTH_PASSWORD=__FOCUS_PASSWORD__
|
|||
# extra options to pass to the jicofo daemon
|
||||
JICOFO_OPTS=""
|
||||
|
||||
# set the max memory used during VM alocation
|
||||
JICOFO_MAX_MEMORY=__MAX_MEMORY__m
|
||||
|
||||
# adds java system props that are passed to jicofo (default are for home and logging config file)
|
||||
JAVA_SYS_PROPS="-Dconfig.file=/etc/__APP__/jicofo/jicofo.conf -Dnet.java.sip.communicator.SC_HOME_DIR_LOCATION=/etc/__APP__ -Dnet.java.sip.communicator.SC_HOME_DIR_NAME=jicofo -Dnet.java.sip.communicator.SC_LOG_DIR_LOCATION=/var/log/__APP__ -Djava.util.logging.config.file=/etc/__APP__/jicofo/logging.properties"
|
||||
|
|
|
@ -12,5 +12,8 @@ JVB_PORT=__PORT_COMPONENT__
|
|||
# sets the shared secret used to authenticate to the XMPP server
|
||||
JVB_SECRET=__VIDEOBRIDGE_SECRET__
|
||||
|
||||
# add max memory used during VM alocation
|
||||
VIDEOBRIDGE_MAX_MEMORY=__MAX_MEMORY__m
|
||||
|
||||
# adds java system props that are passed to jvb (default are for home and logging config file)
|
||||
JAVA_SYS_PROPS="-Dconfig.file=/etc/__APP__/videobridge/jvb.conf -Dnet.java.sip.communicator.SC_HOME_DIR_LOCATION=/etc/__APP__ -Dnet.java.sip.communicator.SC_HOME_DIR_NAME=videobridge -Dnet.java.sip.communicator.SC_LOG_DIR_LOCATION=/var/log/__APP__ -Djava.util.logging.config.file=/etc/__APP__/videobridge/logging.properties"
|
||||
|
|
14
config_panel.toml
Normal file
14
config_panel.toml
Normal file
|
@ -0,0 +1,14 @@
|
|||
version = "1.0"
|
||||
|
||||
[main]
|
||||
name = "Main configuration"
|
||||
services = ["__APP__-jicofo","__APP__-videobridge"]
|
||||
|
||||
[main.config]
|
||||
name = "Global configurations"
|
||||
|
||||
[main.config.max_memory]
|
||||
bind = "null"
|
||||
ask.en = "Max memory to use for VM"
|
||||
type = "number"
|
||||
help = "One user consume about 1,5 Mib memory, for example if plan to have max 50 simultaneous users this parameter should be set to 75 mb"
|
|
@ -4,3 +4,4 @@
|
|||
2. **Jitsi** requires the ports TCP/4443 and UDP/10000 to be forwarded to your YunoHost (The same way you forwarded 80 (HTTP), 443 (HTTPS), etc... https://yunohost.org/#/isp_box_config)
|
||||
3. **Jitsi** will stop and disable Metronome XMPP.
|
||||
4. LDAP authentication is activated, only authenticated users to create new conference rooms. Whenever a new room is about to be created, Jitsi Meet will prompt for a user name and password. After the room is created, others will be able to join from anonymous domain.
|
||||
5. **Jitsi** is configured for 50 users maximum, this number can be increase going to the Yunohost config panel
|
||||
|
|
|
@ -4,3 +4,4 @@
|
|||
2. **Jitsi** demande que les ports TCP/4443 et UDP/10000 soient routés vers votre YunoHost (De la même manière que le sont les ports 80 (HTTP), 443 (HTTPS), etc... https://yunohost.org/#/isp_box_config)
|
||||
3. **Jitsi** va arréter et désactiver le service XMPP Metronome.
|
||||
4. L'authentification LDAP est activée, seuls les utilisateurs authentifiés peuvent créer de nouvelles salles de conférence. Chaque fois qu'une nouvelle salle est sur le point d'être créée, Jitsi Meet vous demandera un nom d'utilisateur et un mot de passe. Une fois la salle créée, d'autres personnes pourront la rejoindre à partir d'un domaine anonyme.
|
||||
5. **Jitsi** est configuré pour 50 utilisateurs maximum, ce nombre peut être augmenté en allant dans le panneau de configuration Yunohost
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
"en": "Video conferencing web application",
|
||||
"fr": "Application web de conférence vidéo"
|
||||
},
|
||||
"version": "1.0.5913~ynh1",
|
||||
"version": "1.0.5913~ynh2",
|
||||
"url": "https://jitsi.org/Projects/JitMeet",
|
||||
"upstream": {
|
||||
"license": "Apache-2.0",
|
||||
|
|
88
scripts/config
Normal file
88
scripts/config
Normal file
|
@ -0,0 +1,88 @@
|
|||
#!/bin/bash
|
||||
|
||||
#=================================================
|
||||
# GENERIC STARTING
|
||||
#=================================================
|
||||
# IMPORT GENERIC HELPERS
|
||||
#=================================================
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
ynh_abort_if_errors
|
||||
|
||||
#=================================================
|
||||
# RETRIEVE ARGUMENTS
|
||||
#=================================================
|
||||
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC GETTERS FOR TOML SHORT KEY
|
||||
#=================================================
|
||||
|
||||
get__max_memory(){
|
||||
local max_memory=$(ynh_app_setting_get --app=$app --key=max_memory)
|
||||
|
||||
# If max_memory doesn't exist, create it and set to default 75 mb value
|
||||
if [ -z "$max_memory" ]; then
|
||||
max_memory=75
|
||||
ynh_app_setting_set --app=$app --key=max_memory --value=$max_memory
|
||||
fi
|
||||
|
||||
cat << EOF
|
||||
value: $max_memory
|
||||
EOF
|
||||
}
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC VALIDATORS FOR TOML SHORT KEYS
|
||||
#=================================================
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC SETTERS FOR TOML SHORT KEYS
|
||||
#=================================================
|
||||
|
||||
set__max_memory(){
|
||||
|
||||
#=================================================
|
||||
# LOAD SETTINGS
|
||||
#=================================================
|
||||
|
||||
ynh_script_progression --message="Loading installation settings..."
|
||||
|
||||
domain=$(ynh_app_setting_get --app=$app --key=domain)
|
||||
path_url=$(ynh_app_setting_get --app=$app --key=path)
|
||||
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
||||
|
||||
focus_user=$(ynh_app_setting_get --app=$app --key=focus_user)
|
||||
focus_password=$(ynh_app_setting_get --app=$app --key=focus_password)
|
||||
focus_secret=$(ynh_app_setting_get --app=$app --key=focus_secret)
|
||||
|
||||
videobridge_user=$(ynh_app_setting_get --app=$app --key=videobridge_user)
|
||||
videobridge_secret=$(ynh_app_setting_get --app=$app --key=videobridge_secret)
|
||||
|
||||
port=$(ynh_app_setting_get --app=$app --key=port)
|
||||
port_videobridge=$(ynh_app_setting_get --app=$app --key=port_videobridge)
|
||||
port_component=$(ynh_app_setting_get --app=$app --key=port_component)
|
||||
|
||||
#=================================================
|
||||
# SET SETTINGS
|
||||
#=================================================
|
||||
|
||||
ynh_app_setting_set --app=$app --key=max_memory --value=$max_memory
|
||||
|
||||
#=================================================
|
||||
# UPDATE CONFIG FILES
|
||||
#=================================================
|
||||
|
||||
ynh_add_config --template="../conf/jitsi-videobridge.config" --destination="/etc/$app/videobridge/config"
|
||||
ynh_add_config --template="../conf/jitsi-jicofo-config" --destination="/etc/$app/jicofo/config"
|
||||
|
||||
ynh_script_progression -l --message="Configuration of $app updated"
|
||||
}
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
#=================================================
|
||||
|
||||
ynh_app_config_run $1
|
|
@ -42,6 +42,8 @@ focus_user="focus"
|
|||
|
||||
videobridge_user="jvb"
|
||||
|
||||
max_memory=75
|
||||
|
||||
#=================================================
|
||||
# CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS
|
||||
#=================================================
|
||||
|
@ -60,6 +62,7 @@ ynh_script_progression --message="Storing installation settings..."
|
|||
|
||||
ynh_app_setting_set --app=$app --key=domain --value=$domain
|
||||
ynh_app_setting_set --app=$app --key=path --value=$path_url
|
||||
ynh_app_setting_set --app=$app --key=max_memory --value=$max_memory
|
||||
ynh_app_setting_set --app=$app --key=focus_user --value=$focus_user
|
||||
ynh_app_setting_set --app=$app --key=focus_password --value=$focus_password
|
||||
ynh_app_setting_set --app=$app --key=focus_secret --value=$focus_secret
|
||||
|
|
|
@ -20,6 +20,8 @@ domain=$(ynh_app_setting_get --app=$app --key=domain)
|
|||
path_url=$(ynh_app_setting_get --app=$app --key=path)
|
||||
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
||||
|
||||
max_memory=$(ynh_app_setting_get --app=$app --key=max_memory)
|
||||
|
||||
focus_user=$(ynh_app_setting_get --app=$app --key=focus_user)
|
||||
focus_password=$(ynh_app_setting_get --app=$app --key=focus_password)
|
||||
focus_secret=$(ynh_app_setting_get --app=$app --key=focus_secret)
|
||||
|
@ -78,6 +80,12 @@ if [ -z "$final_path" ]; then
|
|||
ynh_app_setting_set --app=$app --key=final_path --value=$final_path
|
||||
fi
|
||||
|
||||
# If max_memory doesn't exist, create it and set to default 75 mb value
|
||||
if [ -z "$max_memory" ]; then
|
||||
max_memory=75
|
||||
ynh_app_setting_set --app=$app --key=max_memory --value=$max_memory
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# CREATE DEDICATED USER
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue