pcdsutils.ext_scripts.get_ami_proxy
- pcdsutils.ext_scripts.get_ami_proxy(hutch: str, timeout: float = 10.0)[source]
Call procmgr to determine the lcls-I ami proxy hostname.
This function caches the output.
This works using a regex on the output text from procmgr ami status.
The line we’re looking for always includes the text ami_proxy. The -I argument holds the IP address or hostname of the ami proxy.
I thought the first host in the list was the name of the ami proxy, but this does not seem to be consistent with what the old hutch python is doing, so I will continue to searching for -I here.
- Parameters:
- hutchstr
Name of the hutch to use.
- timeoutint or float
Time to wait for a response from procmgr. Defaults to a 10 second timeout.
- Returns:
- ami_proxystr
The hostname of the server used as a proxy for ami data.