User Tools

Site Tools


computing:voms_script

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
Last revisionBoth sides next revision
computing:voms_script [2017/02/27 14:56] – created iwncomputing:voms_script [2017/07/11 14:51] iwn
Line 1: Line 1:
-Use this code snippet to automatically check whether the VOMS proxy needs to be prolonged:+Use this code snippet in a setup script to automatically check whether the VOMS proxy needs to be prolonged:
 <code> <code>
-if [[ $(voms-proxy-info --timeleft) < 18000 ]]; then # hours+if [[ $(voms-proxy-info --timeleft) < 36000 ]]; then # 10 hours
    echo '>>> voms-proxy-init -voms cms -valid 200:0'    echo '>>> voms-proxy-init -voms cms -valid 200:0'
    voms-proxy-init -voms cms -valid 200:0    voms-proxy-init -voms cms -valid 200:0
 else echo ">>> voms still valid for another `date -u -d @$(voms-proxy-info --timeleft) +"%-d days %-H hours %-M minutes"`" else echo ">>> voms still valid for another `date -u -d @$(voms-proxy-info --timeleft) +"%-d days %-H hours %-M minutes"`"
 fi fi
-<\code>+</code>
computing/voms_script.txt · Last modified: 2020/01/31 13:55 by iwn