[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [HTCondor-users] set environment in job submit file



Hi,

thanks, yes, I know - but the submit environment is not what I target ;) 

I want to overwrite the HOME path on the EP and end up with HOME pointing to _CONDOR_SCRATCH_DIR which is something like '/var/lib/condor/execute/dir_123545' ... 

_CONDOR_SCRATCH_DIR can only be interpreted on the EP of course as it is not known on the submit side ;) 

best
christoph

-- 
Christoph Beyer
DESY Hamburg
IT-Department

Notkestr. 85
Building 02b, Room 009
22607 Hamburg

phone:+49-(0)40-8998-2317
mail: christoph.beyer@xxxxxxx

----- UrsprÃngliche Mail -----
Von: "Max Fischer, SCC" <max.fischer@xxxxxxx>
An: "HTCondor-Users Mail List" <htcondor-users@xxxxxxxxxxx>
CC: "Condor-Users Mail List" <condor-users@xxxxxxxxxxx>
Gesendet: Donnerstag, 27. November 2025 14:13:27
Betreff: Re: [HTCondor-users] set environment in job submit file

Hi Christoph,

Not sure if itâll end up doing what you want, but to get a literal '$ sign you have to use '$(DOLLAR)â. If you want to fetch an environment variable from the submit side, thatâs '$ENV(variable)â instead.

See the section MACROS AND COMMENTS in the condor_submit docs [0] for details.

Cheers,
Max

[0]
https://htcondor.readthedocs.io/en/latest/man-pages/condor_submit.html



> On 27. Nov 2025, at 10:48, Beyer, Christoph <christoph.beyer@xxxxxxx> wrote:
> 
> Hi,
> 
> if I get the manual right something like: 
> 
> Environment = "HOME=$(_CONDOR_SCRATCH_DIR)" 
> 
> Should overwrite the $HOME otherwise set by the starter derived from my submit environment because getenv is set to true. 
> 
> Unfortunately it is not working for me and I tried most of the possible escapes, also setting it to a non-system, individual variable e.g. 'foo' does not work. It seems as if the '$' needs some escaping ? 
> 
> The best result in some permutation is an empty entry for $HOME ... 
> 
> This is in condor 24 but I think likewise in 25 ... 
> 
> Best
> christoph
> 
> -- 
> Christoph Beyer
> DESY Hamburg
> IT-Department
> 
> Notkestr. 85
> Building 02b, Room 009
> 22607 Hamburg
> 
> phone:+49-(0)40-8998-2317
> mail: christoph.beyer@xxxxxxx
> _______________________________________________
> HTCondor-users mailing list
> To unsubscribe, send a message to htcondor-users-request@xxxxxxxxxxx with a
> subject: Unsubscribe
> 
> The archives can be found at: https://www-auth.cs.wisc.edu/lists/htcondor-users/


_______________________________________________
HTCondor-users mailing list
To unsubscribe, send a message to htcondor-users-request@xxxxxxxxxxx with a
subject: Unsubscribe

The archives can be found at: https://www-auth.cs.wisc.edu/lists/htcondor-users/