mirror of
https://github.com/YunoHost-Apps/galene_ynh.git
synced 2024-09-03 18:36:31 +02:00
fix
This commit is contained in:
parent
4e9f86bda6
commit
fae09f9979
4 changed files with 13 additions and 13 deletions
|
@ -8,7 +8,7 @@ Type=simple
|
|||
User=__APP__
|
||||
Group=__APP__
|
||||
WorkingDirectory=__INSTALL_DIR__/live/
|
||||
ExecStart=__INSTALL_DIR__/live/galene -http "127.0.0.1:__PORT__" -insecure -turn __PUBLIC_IP4__:__PORT_TURN__ -udp-range 49152-65535 -groups __DATA_DIR__/groups -recordings __DATA_DIR__/recordings -data __INSTALL_DIR__/live/data/ -static __INSTALL_DIR__/live/static
|
||||
ExecStart=__INSTALL_DIR__/live/galene -http "127.0.0.1:__PORT__" -insecure -turn __PUBLIC_IP4__:__PORT_TURN__ -udp-range 49152-65535 -groups __DATA_DIR__/groups -recordings __DATA_DIR__/recordings -data __INSTALL_DIR__/data/ -static __INSTALL_DIR__/live/static
|
||||
LimitNOFILE=65536
|
||||
|
||||
# Sandboxing options to harden security
|
||||
|
|
|
@ -82,7 +82,7 @@ ram.runtime = "50M"
|
|||
[resources.install_dir]
|
||||
|
||||
[resources.data_dir]
|
||||
subdirs = ["groups", "recordings"]
|
||||
subdirs = ["groups", "recordings", "data"]
|
||||
|
||||
[resources.permissions]
|
||||
main.url = "/"
|
||||
|
|
|
@ -35,7 +35,7 @@ ynh_script_progression --message="Setting up source files..." --weight=1
|
|||
ynh_setup_source --dest_dir="$install_dir/build"
|
||||
ynh_setup_source --dest_dir="$install_dir/build_ldap" --source_id="ldap"
|
||||
|
||||
mkdir -p "$install_dir/live/data"
|
||||
mkdir -p "$install_dir/live"
|
||||
mkdir -p "$install_dir/live_ldap/data"
|
||||
|
||||
cp -r "$install_dir/build/static/" "$install_dir/live/"
|
||||
|
@ -84,9 +84,9 @@ password_hash=$(echo $($install_dir/galene-password-generator $password))
|
|||
ynh_app_setting_set --app=$app --key=password_hash --value="$password_hash"
|
||||
|
||||
# Configure Galène
|
||||
ynh_add_config --template="config.json" --destination="$install_dir/live/data/config.json"
|
||||
chmod 400 "$install_dir/live/data/config.json"
|
||||
chown $app:$app "$install_dir/live/data/config.json"
|
||||
ynh_add_config --template="config.json" --destination="$install_dir/data/config.json"
|
||||
chmod 400 "$install_dir/data/config.json"
|
||||
chown $app:$app "$install_dir/data/config.json"
|
||||
|
||||
# Configure Galène LDAP
|
||||
key=$(jose jwk gen -i '{"kty":"oct","alg":"HS256"}')
|
||||
|
|
|
@ -50,7 +50,7 @@ ynh_script_progression --message="Upgrading source files..." --weight=2
|
|||
ynh_setup_source --dest_dir="$install_dir/build" --full_replace=1
|
||||
ynh_setup_source --dest_dir="$install_dir/build_ldap" --source_id="ldap" --full_replace=1
|
||||
|
||||
mkdir -p "$install_dir/live/data"
|
||||
mkdir -p "$install_dir/data"
|
||||
mkdir -p "$install_dir/live_ldap/data"
|
||||
|
||||
ynh_secure_remove --file="$install_dir/live/static/"
|
||||
|
@ -100,9 +100,9 @@ if [ -z "${password_hash:-}" ]; then
|
|||
ynh_app_setting_set --app=$app --key=password_hash --value="$password_hash"
|
||||
fi
|
||||
# Configure Galène
|
||||
ynh_add_config --template="config.json" --destination="$install_dir/live/data/config.json"
|
||||
chmod 400 "$install_dir/live/data/config.json"
|
||||
chown $app:$app "$install_dir/live/data/config.json"
|
||||
# ynh_add_config --template="config.json" --destination="$install_dir/data/config.json"
|
||||
# chmod 400 "$install_dir/data/config.json"
|
||||
# chown $app:$app "$install_dir/data/config.json"
|
||||
|
||||
# Configure Galène LDAP
|
||||
# If key doesn't exist, create it
|
||||
|
@ -115,9 +115,9 @@ chmod 400 "$install_dir/live_ldap/data/galene-ldap.json"
|
|||
chown $app:$app "$install_dir/live_ldap/data/galene-ldap.json"
|
||||
|
||||
# Create a group name config
|
||||
ynh_add_config --template="groupname.json" --destination="$data_dir/groups/$group_name.json"
|
||||
chmod 400 "$data_dir/groups/$group_name.json"
|
||||
chown $app:$app "$data_dir/groups/$group_name.json"
|
||||
# ynh_add_config --template="groupname.json" --destination="$data_dir/groups/$group_name.json"
|
||||
# chmod 400 "$data_dir/groups/$group_name.json"
|
||||
# chown $app:$app "$data_dir/groups/$group_name.json"
|
||||
|
||||
# Create a group name authenticated on LDAP
|
||||
ynh_add_config --template="groupname-ldap.json" --destination="$data_dir/groups/YunoHost_Users.json"
|
||||
|
|
Loading…
Reference in a new issue