Building Chrome OS behind a proxy - make_chroot issue

526 views
Skip to first unread message

Christophe P

unread,
Jun 12, 2013, 11:57:50 AM6/12/13
to chromium-...@chromium.org
Hi,
I have an issue installing cros-sdk - i'm behind a proxy (doamin authentication recquired) - I'm using cntlm to handle this authentication.
As you can see below everything goes fine until it tries to perform "Running emerge curl sudo"
Does anybody experience same issue ?
When the "running emerge curl sudo" command is performed, it is within the chroot ?
Thanks !
 
christophe@christophe-Virtual-Machine:~/chromiumos$ cros_sdk
Attempting download: https://commondatastorage.googleapis.com/chromiumos-sdk/cros-sdk-2013.06.09.222529.tar.xz

INFO    cros_sdk:make_chroot: Unpacking STAGE3...
INFO    cros_sdk:make_chroot: Set timezone...
INFO    cros_sdk:make_chroot: Adding user/group...

INFO    cros_sdk:make_chroot: Setting up mounts...
INFO    cros_sdk:make_chroot: Running init_setup()...
INFO    cros_sdk:make_chroot: Setting up hosts/resolv...
INFO    cros_sdk:make_chroot: Setting up /etc/make.*...
INFO    cros_sdk:make_chroot: Running post-inst configuration hacks
>>> Regenerating /etc/ld.so.cache...
lrwxrwxrwx 1 root       root      88 Jun 12 17:47 /etc/make.conf -> /mnt/host/source/src/third_party/chromiumos-overlay/chromeos/config/make.conf.amd64-host
lrwxrwxrwx 1 root       root      63 Jun 12 17:47 /etc/make.profile -> /usr/local/portage/chromiumos/profiles/default/linux/amd64/10.0

/usr/local/portage/chromiumos/profiles/default/linux/amd64/10.0:
total 32
drwxr-xr-x 3 christophe chronos 4096 Jun 10 11:25 chromeos
drwxr-xr-x 2 christophe chronos 4096 Jun 10 11:25 desktop
drwxr-xr-x 2 christophe chronos 4096 Jun 10 11:25 developer
-rw-r--r-- 1 christophe chronos    2 Jun 10 11:25 eapi
-rw-r--r-- 1 christophe chronos  410 Jun 10 11:25 make.defaults
drwxr-xr-x 2 christophe chronos 4096 Jun 10 11:25 no-multilib
-rw-r--r-- 1 christophe chronos   29 Jun 10 11:25 parent
drwxr-xr-x 2 christophe chronos 4096 Jun 10 11:25 server
Copying ~/.gitconfig into chroot
INFO    cros_sdk:make_chroot: Updating portage

Performing Global Updates
(Could take a couple of minutes if you have a lot of binary packages.)


>>> Jobs: 0 of 0 complete                           Load avg: 1.03, 0.45, 0.21
INFO    cros_sdk:make_chroot: Updating host toolchain
Starting fast-emerge.
 Building package crossdev on root
Calculating deps...
Deps calculated in 0m0.8s

Total: 0 packages, Size of downloads: 0 kB
Done
Determining required toolchain updates...
Nothing to update!
Nothing to clean!
INFO    cros_sdk:make_chroot: Deselecting dhcpcd
>>> No matching atoms found in "world" favorites file...
INFO    cros_sdk:make_chroot: Running emerge curl sudo ...
Enter username for Cntlm for parent at 127.0.0.1:3128:

Mike Frysinger

unread,
Jun 13, 2013, 12:53:57 AM6/13/13
to gru...@gmail.com, Chromium OS discuss
how are you setting up the proxy ?  by exporting the http_proxy & such env vars ?

then again, why require auth at all on 127.0.0.1 ?  seems like you're asking for pain ...
-mike



--
--
Chromium OS discuss mailing list: chromium-...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-os-discuss?hl=en
 
 
 

Christophe P

unread,
Jun 13, 2013, 8:43:20 AM6/13/13
to chromium-...@chromium.org, gru...@gmail.com
Exact Mike, proxy are set in env vars. It is working for all kind of access except here. I suspect something is not completely relayed inside chroot. 127.0.0.1 recquires authentification because of cntlm. It is the way cntlm is working (my proxy address, login , password, type of auth is set in cntlm conf file)

Mike Frysinger

unread,
Jun 13, 2013, 4:28:31 PM6/13/13
to gru...@gmail.com, Chromium OS discuss
i think it's a matter of this is just the first place it failed because it's the first time files were fetched inside the chroot

if the env vars weren't passed in properly (we have code that does this specifically), then pretty sure the curl fetch wouldn't have even hit that proxy in the first place

however you have curl configured to work outside the chroot (since it seems to require you also set the user/pass and not just the URL), you'll have to do inside the chroot
-mike


Christophe P

unread,
Jun 14, 2013, 3:17:46 AM6/14/13
to chromium-...@chromium.org, gru...@gmail.com
That means i'd need to run cntlm service inside chroot... i don't think it's possible... at least i don't know how :(

Mike Frysinger

unread,
Jun 14, 2013, 8:09:48 PM6/14/13
to gru...@gmail.com, Chromium OS discuss

I don't think so. how is curl working outside the chroot right now?
-mike

Message has been deleted

Christophe P

unread,
Jun 17, 2013, 5:44:42 AM6/17/13
to chromium-...@chromium.org, gru...@gmail.com
Curl is working with no issue outside chroot... even with a blank .curlrc (i think curl is using $http_proxy natively)
So for testing I tried to put $http_proxy also in .curlrc but i'm getting same behavior.... the proxy address is passed in chroot, but not the authentication...
I think the problem is cntlm.conf (it is where proxy authentication data are)
inside chroot the conf is not read and/or applied

Mike Frysinger

unread,
Jun 17, 2013, 11:45:34 AM6/17/13
to Christophe PRATLONG, Chromium OS discuss
try copying it manually into the chroot then
-mike


Christophe P

unread,
Jun 18, 2013, 11:23:57 AM6/18/13
to chromium-...@chromium.org, Christophe PRATLONG
Just did it... same issue :(

Christophe P

unread,
Jun 18, 2013, 12:10:31 PM6/18/13
to chromium-...@chromium.org, Christophe PRATLONG
Here is the command line causing the issue:

early_enter_chroot $EMERGE_CMD -uNv $USEPKG --select $EMERGE_JOBS \
  pbzip2 dev-libs/openssl net-misc/curl sudo
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages