November 4, 20241 yr I made a small script that I need to add to unraid to run periodically. I know of the user scripts package, and I want to use it to execute the script. I have a config.json and the executable. Where to put it? In /boot there I cannot run `chmod +x` on the executable. What is the best practice to make this work?
November 4, 20241 yr 37 minutes ago, eXorQue said: I made a small script that I need to add to unraid to run periodically. I know of the user scripts package, and I want to use it to execute the script. I have a config.json and the executable. Where to put it? In /boot there I cannot run `chmod +x` on the executable. What is the best practice to make this work? I tested and one way to do this is run the script with sh script.sh Instead of trying to do ./script.sh I don't know if this is the "right" way to do it.
November 4, 20241 yr If you're needing to run an actual executable file, you would need to have your script copy it somewhere on the RAM filesystem (like /usr/local/bin/), set +x there, then run the file.
November 5, 20241 yr Author 11 hours ago, EDACerton said: If you're needing to run an actual executable file, you would need to have your script copy it somewhere on the RAM filesystem (like /usr/local/bin/), set +x there, then run the file. So that's something that I should do from the user script as well then? Everytime I run the script, I copy over the executable file, and it's configs and run it from the userscript. Seems cumbersome, but if it's the best practice, I suppose we'll go with it
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.