suite.rc 1.62 KB
Newer Older
Mike Bedington's avatar
Mike Bedington committed
1 2 3 4 5 6 7
#!jinja2
[cylc]
	UTC mode = True # Ignore DST
	abort if any task fails = False

[scheduling]
	initial cycle point = {{INITIAL_START_DATE}}
8
{%- if FINAL_CYCLE_POINT not in ['NONE','None'] %}
Mike Bedington's avatar
Mike Bedington committed
9
	final cycle point = {{FINAL_CYCLE_POINT}}
10
{%- endif %}
Mike Bedington's avatar
Mike Bedington committed
11 12 13
	[[special tasks]]
		clock-trigger = start_cycle(PT0M)
	[[dependencies]]
14
		[[[PT6H]]]
Mike Bedington's avatar
Mike Bedington committed
15
			graph = """
16
					finish_download[-PT6H] => start_cycle => get_GFS_data:finish  & get_CMEMS_data:finish => gfs_proc_data:finish => finish_download
Mike Bedington's avatar
Mike Bedington committed
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
					"""

[runtime]
	[[root]]
		env-script = eval $(rose task-env --cycle-offset=P1D)
		script = rose task-run --verbose
		[[[job]]]
			execution time limit = PT3H
		[[[events]]]
			mail events = submission timeout, execution timeout, failed
			mail to = {{MAIL_TO}}
			submission timeout = P1D
		[[[environment]]]
			START_DATE=$(rose date --print-format='%Y-%m-%d %H:%M:%S' $CYLC_TASK_CYCLE_POINT)
			END_DATE=$(rose date --offset=P1D --print-format='%Y-%m-%d %H:%M:%S' $CYLC_TASK_CYCLE_POINT)
			CMEMS_DATA_DIR={{CMEMS_DATA_DIR}}
33 34
			EURYALE_GFS_ARCHIVE={{EURYALE_GFS_ARCHIVE}}
			CETO_GFS_DIR={{CETO_GFS_DIR}}			
35 36 37 38 39 40 41 42 43
			CETO_DATE_CUTOFF={{CETO_DATE_CUTOFF}}
			GFS_FTP_DIR={{GFS_FTP_DIR}}
        [[remote_job]]
{%- if USE_CETO %}
                [[[remote]]]
                        host = login.ceto.npm.ac.uk
                        owner = {{REMOTE_USER}}
{%- endif %}

Mike Bedington's avatar
Mike Bedington committed
44

45 46 47 48
	[[start_cycle]]
		script = """
			echo "starting download at "${START_DATE}
				"""
Mike Bedington's avatar
Mike Bedington committed
49
	[[get_CMEMS_data]]
50
	[[get_GFS_data]]
51 52
	[[gfs_proc_data]]
                inherit = remote_job		
Mike Bedington's avatar
Mike Bedington committed
53 54 55 56
	[[finish_download]]
        script = """
            echo "finished download for "${START_DATE}
                """
Mike Bedington's avatar
Mike Bedington committed
57