Can Mover start/stop a docker container before it gets invoked?


Recommended Posts

I generally leave my torrents always seeding and it's currently downloading to the cache drive. However when the mover gets invoked everyday it doesn't move those completed downloads from the cache drive to the array because they are still seeding through rutorrent. Is there anyway I can tell mover to stop the rutorrent docker before it gets invoke and start it again once it finishes?

Link to comment

 

49 minutes ago, itimpi said:

Not as such, but you could use the User Scripts plugin to schedule a script to run before mover to shutdown the docker, and at another one to later restart the docker (although you would have to guess at how longer mover needs and thus the timing of that one).

Ya, worst case scenario I was planning on doing that. Would the script be as simple as

 docker stop rutorrent

and

docker start rutorrent

or do I need to do any checks before stopping/starting it?

Edited by bobokun
Link to comment
7 hours ago, itimpi said:

(although you would have to guess at how longer mover needs and thus the timing of that one).

Alternatively, you can disable mover from running automatically as per the directions here:  https://forums.lime-technology.com/topic/48707-additional-scripts-for-userscripts-plugin/#comment-483789 and then use user scripts to manage everything  (Note that this is a hack, and any changes to a setting in the scheduler will undo this change)

 

docker stop rutorrent
mover
docker start rutorrent

Although it would probably be good to specify the time to wait for a graceful shutdown of rutorrent before killing it:

docker stop -t 60 rutorrent

so that rutorrent won't have to recheck all of the files when it starts back up.

 

Link to comment
On 7/24/2017 at 5:40 PM, Squid said:

Alternatively, you can disable mover from running automatically as per the directions here:  https://forums.lime-technology.com/topic/48707-additional-scripts-for-userscripts-plugin/#comment-483789 and then use user scripts to manage everything  (Note that this is a hack, and any changes to a setting in the scheduler will undo this change)

 


docker stop rutorrent
mover
docker start rutorrent

Although it would probably be good to specify the time to wait for a graceful shutdown of rutorrent before killing it:

 


docker stop -t 60 rutorrent

so that rutorrent won't have to recheck all of the files when it starts back up.

 

I noticed that the script doesn't seem to execute the mover command.

Do you know what the full path of mover is?

This is my script:

 

#!/bin/bash
echo "Stopping rutorrent"
docker stop ----time=60 rutorrent
echo "executing mover"
mover
echo "Mover Complete. Starting Rutorrent docker"
docker start rutorrent
echo "Successfully started rutorrent"
 

 

Output Log:

Stopping rutorrent
rutorrent
executing mover
/tmp/user.scripts/tmpScripts/mover (Stopping dockers)/script: line 5: mover: command not found
Mover Complete. Starting Rutorrent docker
rutorrent
Successfully started rutorrent

 

Edited by bobokun
Link to comment
  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.