Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The Configuration File might look like this:

Code Block
languagetext
host=mediaflux.researchsoftware.unimelb.edu.au
port=443
transport=https
token=phooP1Angohb2ooyahbiLiuwa6ahjuoKooViedaifooPhiqu1ookahXae7keichael4Shae2ael8ietit2phawucai0Aighifu6olah9OquahDei2aevae3keich8ain1OoLa4O

...

Create a Configuration File.  In this case we are going to use a secure token.  In our example, it will be stored in %HOMEPATH%\Documents\mflux.cfg.

Code Block
languagetext
host=mediaflux.researchsoftware.unimelb.edu.au
port=443
transport=https
token=phooP1Angohb2ooyahbiLiuwa6ahjuoKooViedaifooPhiqu1ookahXae7keichael4Shae2ael8ietit2phawucai0Aighifu6olah9OquahDei2aevae3keich8ain1OoLa4O

Create a batch file to perform the upload using Notepad.  In our example, it will be stored in %HOMEPATH%\Documents\upload.bat:

Code Block
languagetext
%HOMEPATH%\Documents\unimelb-mf-clients-0.7.7\bin\windows\unimelb-mf-upload --mf.config %HOMEPATH%\Documents\mflux.cfg --log-dir %HOMEPATH%\Documents\logs --dest /projects/proj-demonstration-1128.4.15 %HOMEPATH%\Documents\data-to-upload

...

Create a Configuration File.  In this case we are going to use a secure token.  In our example, it will be stored in ~/.Arcitecta/mflux.cfg.

Code Block
languagetext
host=mediaflux.researchsoftware.unimelb.edu.au
port=443
transport=https
token=phooP1Angohb2ooyahbiLiuwa6ahjuoKooViedaifooPhiqu1ookahXae7keichael4Shae2ael8ietit2phawucai0Aighifu6olah9OquahDei2aevae3keich8ain1OoLa4O

Create a shell script to perform the upload using the text editor of your choice.  In our example, it will be stored in ~/bin/upload.sh:

Code Block
languagebash
#!/bin/bash
~/bin/unimelb-mf-clients-0.7.4/bin/unix/unimelb-mf-upload --mf.config ~/.Arcitecta/mflux.cfg --log-dir ~/logs --dest /projects/proj-demonstration-1128.4.15 ~/data-to-upload

...

Edit the crontab file with the following command:

Code Block
languagebash
crontab -e

Create a new scheduled task at the end of the crontab file.  To see documentation on the format, try the man 5 crontab command.  In our example, we will run the command once per day at 1 am local time.

Code Block
languagebash
# To define the time you can provide concrete values for
# minute (m), hour (h), day of month (dom), month (mon),
# and day of week (dow) or use '*' in these fields (for 'any').
#
# For more information see the manual pages of crontab(5) and cron(8)
# 
# m h  dom mon dow   command
0 1 * * * $HOME/bin/upload.sh

Save the file, and your job will be scheduled.

Code Block
languagetext
crontab: installing new crontab

...