@@ -22,19 +22,20 @@ In this example, we set the routed job on hold if the job is idle and has been s
2222tried to start more than once.
2323This will catch jobs which are starting and stopping multiple times.
2424
25- ```hl_lines="5 8"
26- JOB_ROUTER_ROUTE_Condor_Pool @=jrt
27- UNIVERSE VANILLA
28- # Puts the routed job on hold if the job's been idle and has been started at least
29- # once or if the job has tried to start more than once
30- SET PeriodicHold ((NumJobStarts >= 1 && JobStatus == 1) || NumJobStarts > 1)
31- # Release routed jobs if the condor_starter couldn't start the executable and
32- # 'VMGAHP_ERR_INTERNAL' is in the HoldReason
33- SET PeriodicRelease = (HoldReasonCode == 6 && regexp("VMGAHP_ERR_INTERNAL", HoldReason))
34- @jrt
35-
36- JOB_ROUTER_ROUTE_NAMES = Condor_Pool
37- ```
25+ ``` hl_lines="5 8"
26+ JOB_ROUTER_ROUTE_Condor_Pool @=jrt
27+ UNIVERSE VANILLA
28+ # Puts the routed job on hold if the job's been idle and has been started at least
29+ # once or if the job has tried to start more than once
30+ SET PeriodicHold ((NumJobStarts >= 1 && JobStatus == 1) || NumJobStarts > 1)
31+ # Release routed jobs if the condor_starter couldn't start the executable and
32+ # 'VMGAHP_ERR_INTERNAL' is in the HoldReason
33+ SET PeriodicRelease = (HoldReasonCode == 6 && regexp("VMGAHP_ERR_INTERNAL", HoldReason))
34+ @jrt
35+
36+ JOB_ROUTER_ROUTE_NAMES = Condor_Pool
37+ ```
38+
3839Setting routed job requirements
3940-------------------------------
4041
@@ -47,14 +48,14 @@ For more information on requirements, consult the
4748
4849To ensure that your job lands on a Linux machine in your pool:
4950
50- ```hl_lines="3"
51- JOB_ROUTER_ROUTE_Condor_Pool @jrt
52- UNIVERSE VANILLA
53- SET Requirements = (TARGET.OpSys == "LINUX")
54- @jrt
51+ ``` hl_lines="3"
52+ JOB_ROUTER_ROUTE_Condor_Pool @jrt
53+ UNIVERSE VANILLA
54+ SET Requirements = (TARGET.OpSys == "LINUX")
55+ @jrt
5556
56- JOB_ROUTER_ROUTE_NAMES = Condor_Pool
57- ```
57+ JOB_ROUTER_ROUTE_NAMES = Condor_Pool
58+ ```
5859
5960### Preserving original job requirements ###
6061
@@ -63,9 +64,9 @@ Requirements` or `copy_Requirements` to store the current value of `Requirements
6364` original_requirements ` .
6465To do this, replace the above ` SET Requirements ` or ` set_Requirements ` lines with:
6566
66- ```
67- SET Requirements = ($(MY.Requirements)) && (<YOUR REQUIREMENTS EXPRESSION>)
68- ```
67+ ```
68+ SET Requirements = ($(MY.Requirements)) && (<YOUR REQUIREMENTS EXPRESSION>)
69+ ```
6970
7071### Setting the accounting group based on the credential of the submitted job ###
7172
@@ -82,18 +83,18 @@ Because of this, the default CE config will copy all attributes that match `Auth
8283
8384Example of setting the accounting group from AuthToken or x509 attributes.
8485
85- ```
86- JOB_ROUTER_CLASSAD_USER_MAP_NAMES = $(JOB_ROUTER_CLASSAD_USER_MAP_NAMES) AcctGroupMap
87- CLASSAD_USER_MAPFILE_AcctGroupMap = <path-to-mapfile>
86+ ```
87+ JOB_ROUTER_CLASSAD_USER_MAP_NAMES = $(JOB_ROUTER_CLASSAD_USER_MAP_NAMES) AcctGroupMap
88+ CLASSAD_USER_MAPFILE_AcctGroupMap = <path-to-mapfile>
8889
89- JOB_ROUTER_TRANSFORM_SetAcctGroup @=end
90- REQUIREMENTS (orig_AuthTokenSubject ?: x509UserProxySubject) isnt undefined
91- EVALSET AcctGroup UserMap("AcctGroupMap", orig_AuthTokenSubject ?: x509UserProxySubject, AcctGroup)
92- EVALSET AccountingGroup join(".", AcctGroup, Owner)
93- @end
90+ JOB_ROUTER_TRANSFORM_SetAcctGroup @=end
91+ REQUIREMENTS (orig_AuthTokenSubject ?: x509UserProxySubject) isnt undefined
92+ EVALSET AcctGroup UserMap("AcctGroupMap", orig_AuthTokenSubject ?: x509UserProxySubject, AcctGroup)
93+ EVALSET AccountingGroup join(".", AcctGroup, Owner)
94+ @end
9495
95- JOB_ROUTER_PRE_ROUTE_TRANSFORMS = $(JOB_ROUTER_PRE_ROUTE_TRANSFORMS) SetAcctGroup
96- ```
96+ JOB_ROUTER_PRE_ROUTE_TRANSFORMS = $(JOB_ROUTER_PRE_ROUTE_TRANSFORMS) SetAcctGroup
97+ ```
9798
9899Refer to the HTCondor documentation for [ information on mapfiles] ( https://htcondor.readthedocs.io/en/lts/admin-manual/security.html?highlight=mapfile#the-unified-map-file-for-authentication ) .
99100
0 commit comments