Setup a Ponos agent on JeanZay¶
To easily set up a Ponos agent on JeanZay , you can follow the example below which allows you to launch any Arkindex process:
- Create a
$HOME/.netrc
file to allow Ponos to download repositories. You need a personal access token with scoperead_api
. You will need to add the following to your$HOME/.netrc
file:machine gitlab.teklia.com login __token__ password <YOUR_PERSONAL_TOKEN>
- Create a
$HOME/configs
folder with aconfig.yml
file following the instructions described here . - Run the following script:
#!/bin/bash # Delete **all** # :warning: Save your Ponos files if needed rm -rf $HOME/.local $HOME/.cache $HOME/ponos $SCRATCH/ponos # (re)Install virtualenv module load python/3.10.4 pip install virtualenv --no-cache-dir export PATH="$PATH:$HOME/.local/bin" # Create base dir/env cd $HOME mkdir ponos && cd ponos virtualenv . source bin/activate # Allow Ponos to create virtualenvs pip install virtualenv --no-cache-dir # Install Ponos cd $HOME/ponos git clone https://gitlab.teklia.com/arkindex/ponos-agent.git agent && cd agent pip install . --no-cache-dir # Install PySlurm cd $HOME/ponos # Check Slurm compatibility sinfo --version # slurm 23.02.6 git clone https://github.com/PySlurm/pyslurm.git && cd pyslurm # Checkout to respect Slurm compatibility git checkout 23.2.x # Use a specific version of Slurm export SLURM_INCLUDE_DIR=/gpfslocalsys/slurm/slurm-23.02.6/include export SLURM_LIB_DIR=/gpfslocalsys/slurm/slurm-23.02.6/lib # Respect PySlurm compatibility pip install "cython>=0.29.30<3.0" --no-cache-dir pip install . --no-cache-dir # If build fails, this may come from https://github.com/PySlurm/pyslurm/pull/325 git cherry-pick f7a7d8beb8ceb4e4c1b248bab2ebb995dcae77e2 pip install . --no-cache-dir
At the end you should have the following file structure:
$HOME/
├── configs
│ └── config.yml
└── ponos
├── agent
└── pyslurm
Now you can simply launch:
source $HOME/ponos/bin/activate
ponos-agent $HOME/configs/config.yml