mirror of https://github.com/InternLM/InternLM
fix(monitor): add volc and aliyun jobid (#338)
* add volc and aliyun jobid * rm workspaceidpull/367/head
parent
064965527b
commit
847cc819dd
|
@ -14,8 +14,10 @@ def get_job_id():
|
||||||
job_id = "none"
|
job_id = "none"
|
||||||
if os.getenv("SLURM_JOB_ID") is not None:
|
if os.getenv("SLURM_JOB_ID") is not None:
|
||||||
job_id = os.getenv("SLURM_JOB_ID")
|
job_id = os.getenv("SLURM_JOB_ID")
|
||||||
elif os.getenv("K8S_WORKSPACE_ID") is not None:
|
elif os.getenv("KUBERNETES_POD_NAME") is not None:
|
||||||
job_id = os.getenv("K8S_WORKSPACE_ID")
|
job_id = os.getenv("KUBERNETES_POD_NAME").split("-")[0]
|
||||||
|
elif os.getenv("MLP_TASK_INSTANCE_ID") is not None:
|
||||||
|
job_id = os.getenv("MLP_TASK_ID")
|
||||||
|
|
||||||
return job_id
|
return job_id
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue