1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/sonarr_ynh.git synced 2024-09-03 20:26:19 +02:00

Upgrade config file to disable internal auth mechanism

This commit is contained in:
tituspijean 2024-02-06 19:11:25 +01:00
parent 460a2fc1b0
commit 84957bbb6d
No known key found for this signature in database
GPG key ID: EF3B0D7CC0A94720
3 changed files with 23 additions and 1 deletions

View file

@ -1,5 +1,5 @@
<Config>
<LogLevel>info</LogLevel>
<LogLevel>warn</LogLevel>
<EnableSsl>False</EnableSsl>
<Port>__PORT__</Port>
<SslPort>__PORT__</SslPort>
@ -9,4 +9,10 @@
<AuthenticationMethod>None</AuthenticationMethod>
<UpdateMechanism>BuiltIn</UpdateMechanism>
<Branch>main</Branch>
<LaunchBrowser>False</LaunchBrowser>
<AnalyticsEnabled>False</AnalyticsEnabled>
<InstanceName>Sonarr</InstanceName>
<AuthenticationRequired>DisabledForLocalAddresses</AuthenticationRequired>
<SslCertPath></SslCertPath>
<SslCertPassword></SslCertPassword>
</Config>

View file

@ -0,0 +1,5 @@
The app's `__DATA_DIR__/config.xml` will now be overidden upon every upgrade. This is to make sure the internal authentication system is disabled, since you can benefit from YunoHost's permission system.
In most use cases it should be fine. If you do need to alter the file, refer to the hooks system.
If you altered the file, a backup has been made in `__DATA_DIR__`.

View file

@ -55,6 +55,17 @@ yunohost service add "$app" --description="Sonarr daemon" --log="/var/log/$app/s
# Use logrotate to manage app-specific logfile(s)
ynh_use_logrotate --non-append --logfile="/var/log/$app/"
#=================================================
# ADD A CONFIGURATION
#=================================================
ynh_script_progression --message="Configuring Radarr..." --weight=2
ynh_add_config --template="config.xml" --destination="$data_dir/config.xml"
chmod 750 "$data_dir"
chmod -R o-rwx "$data_dir"
chown -R "$app:$app" "$data_dir"
#=================================================
# START SYSTEMD SERVICE
#=================================================