diff --git a/conf/ServerConfig.json b/conf/ServerConfig.json new file mode 100644 index 0000000..d59695c --- /dev/null +++ b/conf/ServerConfig.json @@ -0,0 +1,19 @@ +{ + "Port": 9117, + "AllowExternal": true, + "APIKey": "s9tcqkddvjpkmis824pp6ucgpwcd2xnc", + "AdminPassword": null, + "InstanceId": "4ylb3rfzbzc0bqils4zswsvbyq9o4armfsxjzlo0w1z853svngr2m82cd8cij9u2", + "BlackholeDir": "", + "UpdateDisabled": false, + "UpdatePrerelease": true, + "BasePathOverride": "__PATH_URL__", + "OmdbApiKey": "", + "OmdbApiUrl": "", + "ProxyUrl": "", + "ProxyType": 0, + "ProxyPort": null, + "ProxyUsername": "", + "ProxyPassword": "", + "ProxyIsAnonymous": true +} diff --git a/scripts/install b/scripts/install index 703b4c4..ac718b2 100755 --- a/scripts/install +++ b/scripts/install @@ -101,13 +101,7 @@ ynh_add_systemd_config #================================================= ynh_script_progression --message="Configuring Jackett..." --weight=2 -# Start a systemd service -ynh_systemd_action --service_name=$app --action="start" --log_path="systemd" --line_match="Hosting environment: Production" --timeout=30 -# Start a systemd service -ynh_systemd_action --service_name=$app --action="stop" --log_path="systemd" - -target_string=$(echo \"BasePathOverride\": \"$path_url\") -sed --in-place "s@\"BasePathOverride\": null@${target_string}@g" "$final_path/.config/Jackett/ServerConfig.json" +ynh_add_config --template="../conf/ServerConfig.json" --destination="$final_path/.config/Jackett/ServerConfig.json" #================================================= # GENERIC FINALIZATION @@ -132,7 +126,7 @@ yunohost service add $app --description="API support for torrent trackers" --log ynh_script_progression --message="Starting a systemd service..." # Start a systemd service -ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" +ynh_systemd_action --service_name=$app --action="restart" --log_path="systemd" #================================================= # SETUP SSOWAT