A note to self. I tried this on Ubuntu 22.04.1 LTS under WSL2.
curl https://pyenv.run | bash
# Assumes make and gcc are already installed
sudo apt install zlib1g-dev libssl-dev
Then add the following to .bashrc.
export PATH="$HOME/.pyenv/bin:$PATH"
Apply it with the source command, and that’s it.
COMMENTS