How can I checkout password-protected subversion repositories with bitbake?
I am having an issue regarding the svn fetcher of OpenEmbedded/bitbake. When I use:
svn://PATH/;proto=https;module=trunk
or
svn://PATH/;proto=https;module=trunk;username=ABC;password=XYZ
bitbake won't do anything. It just waits after:
NOTE: Fetch
svn://DOMAIN/svn/src/www/home/trunk/resources/tree/src/metadata-input/trunk/;proto=https;modul开发者_如何学Pythone=trunk
Authentication realm: <https://DOMAIN.de:443> svn/src/www
I tried typing in my password or username then password but nothing happens.
After I cancel with Control-C
I get a prompt on the command line:
Password for 'USERNAME':
Can someone please give me a hint on solving this? Switching to http
or
svn+ssh
is not an option in my company.
The parameters should be user= and pswd=, e.g.:
svn://PATH/;proto=https;module=trunk;user=bob;pswd=password
Under newer versions of bitbake
provided with yocto, you would make a recipe that looks something like this (line breaks for clarity):
SRC_URI= "svn://svn.example.com/svnreponame/trunk/;\
module=HelloWorld;\
protocol=https;\
user=jrandom;\
pswd= \
"
Note that "module" is just the name of the directory to check out from subversion's perspective.
I've left the password off so it isn't stored in your source-code control system with the rest of the recipe. If you provide a username without a password in the recipe, subversion will look for cached credentials in its usual places. Checking out a working copy elsewhere on the machine with the build user should be sufficient to trigger subversion to ask about caching credentials.
Try setting up a .netrc
file in your home directory containing the username and password to your server. Bitbake uses wget
to fetch files, which in turn reads .netrc
for passwords.
For example, you could add to your ~/.netrc
file a single line:
machine example.com login john.smith password ABC123
to inform wget
to login to example.com
with username john.smith
and password ABC123
.
精彩评论