Importing a private repo into another private repo within Travis CI/CD

I have several repos which are already setup nicely in a Travis CI/CD pipeline. Some of these repos are “green”, and seem to be working as they should. However some of these repos, rely on a “base” repo, which is just another private repo. We’re using Guthub and Python.

I’ve tried numerous combinations with importing via the requirements.txt file, .travis.yml. There are also files in every repo.

The documents on Travis’s website have so far not been able to resolve the issue. Further, it is not clear to me whether I should use ssh or https.

In Docker the current configuration is so:

RUN git clone --config core.sshCommand="ssh -o 'StrictHostKeyChecking no' -i /opt/app/.ssh/id_ed25519"
ENV NSABASE_PATH "/opt/BaseRepo/"

The current Traceback from a Travis run (git push) is:

Cloning into '/home/travis/build/myname/Repo1/submodule/BaseRepo'...
ERROR: Permission to myname/BaseRepo.git denied to deploy key
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
fatal: clone of '' into submodule path '/home/travis/build/myname/Repo1/submodule/BaseRepo' failed
Failed to clone 'submodule/BaseRepo'. Retry scheduled

Can anyone indicate where I am going wrong with importing a repo from a private Github account, into another repo, within the Travis CI/CD framework?

Please check this doc on how to download private dependencies: