How to make created custom (conda) environments persist across user sessions in Jupyter Hub on AWS EKS cluster

Thanks for sharing file. Although, in Notebook, we’ve better way to run pre-start scripts before notebook actual starts. click here for more info
So, you can keep a script file inside a folder /usr/local/bin/start-notebook.d. The run-hooks function looks for .sh scripts to source and executable files to run within a passed directory. You can keep a script which will perform all above copying operations and can setup .condarc file on fly like this

CONDARC_FILE=~/.condarc
if [ -f "$CONDARC_FILE" ]; then
    echo "conda configuration exists."
else 
    echo "$CONDARC_FILE does not exist. writing one..."
    cat > "$CONDARC_FILE" <<EOF
envs_dirs:
  - /home/jovyan/.conda-envs/
EOF
fi