Reputation: 723
I'm trying to copy a small text file from/to locations which are located under different subfolders of the "web" main folder.
The source is 'web/Domoos/php_scripts/auto/file/myfox_token.txt' and the destination is 'web/Demo/0h/php_scripts/auto/file/myfox_token.txt'.
Based on a previous post on stackoverflow (Copying local files with curl), I have tried to implement this logic in my Synology DS415+, which runs under DSM version 6.2.3 (Update 2) by adding a new task and entering the following in the command line:
curl -o file://"web/Domoos/php_scripts/auto/file/myfox_token.txt" > "web/Demo/0h/php_scripts/auto/file/myfox_token.txt"
Unfortunately, I was not successful. Then I tried to enter the same using the IP address of my NAS (192.168.X.X) :
curl -o "192.168.X.X/web/Domoos/php_scripts/auto/file/myfox_token.txt" > "192.168.X.X/web/Demo/0h/php_scripts/auto/file/myfox_token.txt"
This was not successful, either.
Could it be that the "curl" function is not supported on Synology as I would like it to be ?
Many thanks for reading my post and best wishes.
Upvotes: 0
Views: 8377
Reputation: 723
I respond to myself, hoping that this post could be helpful to someone else.
I created a bash script and went in the 3rd tab of the task scheduler editor "task settings".
I entered the following
#!/bin/bash
# For demo 0h folder
sleep 15s
cp /volume1/web/Domoos/php_scripts/auto/file/myfox_token_extracted.txt /volume1/web/Demo/0h/php_scripts/auto/file/myfox_token_extracted.txt
Please keep in mind that :
Best wishes and stay healthy
Upvotes: 3