Compare commits

...

2 Commits

Author SHA1 Message Date
1c16243a2d Bump version to 2.0.5 and update changelog
- Update version number in package.json to 2.0.5
- Add changelog entry for version 2.0.5 with recent fixes:
  - Config file properly stored in /etc/transmission-rss-manager
  - Fixed remote Transmission detection in install-script.sh
  - Enhanced symlink handling between installation and config directories
  - Better environment variable passing between install scripts
2025-03-05 09:49:30 +00:00
306049abdd Fix config directory handling in install script
- Ensure CONFIG_DIR exists during installation
- Create proper symlink from INSTALL_DIR/config.json to CONFIG_DIR/config.json
- Use CONFIG_DIR instead of INSTALL_DIR for configuration files
- Add code to move existing config file to CONFIG_DIR if needed

This fixes the issue where the config.json file was not being created in /etc/transmission-rss-manager, even though the directory was created.
2025-03-05 09:47:29 +00:00
3 changed files with 39 additions and 5 deletions

View File

@ -1,9 +1,15 @@
# Transmission RSS Manager v2.0.4 # Transmission RSS Manager v2.0.5
A comprehensive web-based tool to automate and manage your Transmission torrent downloads with RSS feed integration, intelligent media organization, and enhanced security features. Now with automatic updates and easy installation! A comprehensive web-based tool to automate and manage your Transmission torrent downloads with RSS feed integration, intelligent media organization, and enhanced security features. Now with automatic updates and easy installation!
## Changelog ## Changelog
### v2.0.5 (2025-03-05)
- **Fixed**: Config file now properly stored in /etc/transmission-rss-manager directory
- **Fixed**: Remote Transmission detection in install-script.sh
- **Improved**: Enhanced symlink handling between installation dir and config dir
- **Improved**: Better environment variable passing between install scripts
### v2.0.4 (2025-03-05) ### v2.0.4 (2025-03-05)
- **Fixed**: Remote transmission detection in installer - **Fixed**: Remote transmission detection in installer
- **Fixed**: Configuration directory creation and permissions - **Fixed**: Configuration directory creation and permissions

View File

@ -104,6 +104,26 @@ function finalize_setup() {
mkdir -p "$INSTALL_DIR/logs" mkdir -p "$INSTALL_DIR/logs"
log "INFO" "Created logs directory: $INSTALL_DIR/logs" log "INFO" "Created logs directory: $INSTALL_DIR/logs"
# Ensure CONFIG_DIR exists
if [ ! -d "$CONFIG_DIR" ]; then
mkdir -p "$CONFIG_DIR"
log "INFO" "Created configuration directory: $CONFIG_DIR"
chown -R "$USER:$USER" "$CONFIG_DIR"
fi
# Check if the config symlink exists, create it if not
if [ ! -L "$INSTALL_DIR/config.json" ] || [ ! -e "$INSTALL_DIR/config.json" ]; then
# If there's a real file at INSTALL_DIR/config.json (not a symlink), move it to CONFIG_DIR
if [ -f "$INSTALL_DIR/config.json" ] && [ ! -L "$INSTALL_DIR/config.json" ]; then
log "INFO" "Moving existing config.json to $CONFIG_DIR"
mv "$INSTALL_DIR/config.json" "$CONFIG_DIR/config.json"
fi
# Create the symlink
ln -sf "$CONFIG_DIR/config.json" "$INSTALL_DIR/config.json"
log "INFO" "Created symlink from $INSTALL_DIR/config.json to $CONFIG_DIR/config.json"
fi
# Set proper ownership for the installation directory # Set proper ownership for the installation directory
chown -R $USER:$USER $INSTALL_DIR chown -R $USER:$USER $INSTALL_DIR
@ -124,7 +144,7 @@ function finalize_setup() {
cd $INSTALL_DIR && npm install cd $INSTALL_DIR && npm install
# Handle configuration file # Handle configuration file
if ! update_config_file "$INSTALL_DIR/config.json" "$IS_UPDATE"; then if ! update_config_file "$CONFIG_DIR/config.json" "$IS_UPDATE"; then
log "INFO" "Creating default configuration file..." log "INFO" "Creating default configuration file..."
# Create the users array content for JSON # Create the users array content for JSON
@ -133,7 +153,10 @@ function finalize_setup() {
USER_JSON="{ \"username\": \"${ADMIN_USERNAME}\", \"password\": \"${ADMIN_PASSWORD}\", \"role\": \"admin\" }" USER_JSON="{ \"username\": \"${ADMIN_USERNAME}\", \"password\": \"${ADMIN_PASSWORD}\", \"role\": \"admin\" }"
fi fi
cat > $INSTALL_DIR/config.json << EOF # Make sure CONFIG_DIR exists
mkdir -p "$CONFIG_DIR"
cat > $CONFIG_DIR/config.json << EOF
{ {
"version": "1.2.0", "version": "1.2.0",
"transmissionConfig": { "transmissionConfig": {
@ -188,7 +211,12 @@ function finalize_setup() {
"logLevel": "info" "logLevel": "info"
} }
EOF EOF
chown $USER:$USER $INSTALL_DIR/config.json # Set ownership for the config file
chown $USER:$USER $CONFIG_DIR/config.json
# Ensure symlink exists from INSTALL_DIR to CONFIG_DIR
ln -sf "$CONFIG_DIR/config.json" "$INSTALL_DIR/config.json"
log "INFO" "Created symlink from $INSTALL_DIR/config.json to $CONFIG_DIR/config.json"
log "INFO" "Default configuration created successfully" log "INFO" "Default configuration created successfully"
fi fi

View File

@ -1,6 +1,6 @@
{ {
"name": "transmission-rss-manager", "name": "transmission-rss-manager",
"version": "2.0.4", "version": "2.0.5",
"description": "A comprehensive web-based tool to automate and manage your Transmission torrent downloads with RSS feed integration and intelligent media organization", "description": "A comprehensive web-based tool to automate and manage your Transmission torrent downloads with RSS feed integration and intelligent media organization",
"main": "server.js", "main": "server.js",
"scripts": { "scripts": {