in the CMS open data containers or in the CMS Shell in the VM image.
Alternatively, clone the repository normally with git clone https... in a more recent environment:
if using containers, in your local area, which you mount as a volume to the container
if using VM, in the terminal with a more recent OS, which opens from a terminal icon on the bottom of the desktop screen (remember that in the VM, building the CMSSW area and compiling must be done in the CMS shell)
In addition to the above, if you are using containers and you want to be able to access the ssh keys needed to clone repos, for example from Github, you’ll want to launch the container such that the keys are accessible from inside the container.
docker run --it -v ${HOME}/.ssh:/home/cmsusr/.ssh ...
As a more complete example, I run the following to start a CMSSW 5.3.32 container instance making sure that I a) can access my ssh keys and b) will have X11 forwarding enabled.
docker run -it -v ${HOME}/.ssh:/home/cmsusr/.ssh --net=host --env="DISPLAY" --volume="$HOME/.Xauthority:/root/.Xauthority:rw" cmsopendata/cmssw_5_3_32 /bin/bash
Can you confirm the container image you are using?
If you are using cmsopendata/cmssw_5_3_32these instructions should work.
Note that you should not submit cmsenv command in the container as it changes git back to older versions. The container environment is set up and ready to use at the start-up without additional commands.
Hope this help and if not, please list the exact command so that we can reproduce.
I’m glad that helps! That’s a good question also for the experienced I believe the easiest thing is to exit from the container and start it again (docker start -i <container-name>)
To see if it helps you can type git --version before exiting and again when you have started and if the output is different then you’re back to the correct environment.
If you are using the VM, then you should indeed submit cmsenv in the “CMS shell” once you’ve built your CMSSW area.
But you will then use the other shell (“Outer shell”) for git as it has a different, more recent environment where you should be able to use the git clone https://... syntax.
But do not submit cmsenv in the “Outer shell”, it will change the git version there.
Remember to do all compiling (scram b) in the “CMS shell”.
This is all due to the challenge of providing the correct environment for open data, but still trying to adapt to the changes in the surrounding world.