Fedora Linux Support Community & Resources Center

Go Back   FedoraForum.org > Fedora Resources > Guides & Solutions (Not For Questions)
FedoraForum Search

Forgot Password? Join Us!

Guides & Solutions (Not For Questions) Post your guides here (No links to Blogs accepted). You can also append your comments/questions to a guide, but don't start a new thread to ask a question. Use another forum for that.

Reply
 
Thread Tools Search this Thread Display Modes
  #61  
Old 9th March 2008, 05:46 PM
Duli Offline
Registered User
 
Join Date: Jul 2006
Location: Sao Paulo, SP - Brazil
Age: 37
Posts: 712
Quote:
Originally Posted by bmvbab
Hi Sorry for the delay, http_proxy is the env variable to look for. If some one is using proxy then they should have exported http_proxy with something like http://www.proxy.com:8080
So for rpms u should be using --httphost=www.proxy.com --httpport=8080
If http_proxy is not set then we cannot do anything....
Hum, ok, and what about wget? Does it use that variable also?

Thanks
duli
Reply With Quote
  #62  
Old 10th March 2008, 06:43 AM
bmvbab Offline
Registered User
 
Join Date: Jun 2005
Location: India
Age: 36
Posts: 376
wget makes use of http_proxy. If that value is exported it is utilized and if not it assumes its a direct connection, wget also has an option --no-proxy which makes it not use proxy even if http_proxy is exported.
Reply With Quote
  #63  
Old 10th March 2008, 07:20 AM
leadgolem Offline
Registered User
 
Join Date: Apr 2005
Location: Littleton, CO
Age: 32
Posts: 2,857
Me thinks the subshell may be dropping the variable.
__________________
S.C.O.U.R.G.E. Heroes of lesser renown, contributor.
Reply With Quote
  #64  
Old 10th March 2008, 08:08 AM
bmvbab Offline
Registered User
 
Join Date: Jun 2005
Location: India
Age: 36
Posts: 376
Quote:
Originally Posted by leadgolem
Me thinks the subshell may be dropping the variable.
Any pointers on how to get the values across to the new shell from the env variables?
Reply With Quote
  #65  
Old 10th March 2008, 08:45 AM
leadgolem Offline
Registered User
 
Join Date: Apr 2005
Location: Littleton, CO
Age: 32
Posts: 2,857
Something like this in the initial script might do it.
Code:
export http_proxy="$http_proxy"
Though I find it odd this variable is in lowercase letters...

EDIT: This also assumes that the "http_proxy" variable is accessible in the initial script. If it is not, then you would want to use something more like this.
Code:
export http_proxy="http://www.proxy.com:8080"
Though that won't help anyone else using a proxy server.
__________________
S.C.O.U.R.G.E. Heroes of lesser renown, contributor.

Last edited by leadgolem; 10th March 2008 at 08:56 AM.
Reply With Quote
  #66  
Old 10th March 2008, 09:07 AM
bmvbab Offline
Registered User
 
Join Date: Jun 2005
Location: India
Age: 36
Posts: 376
Quote:
Originally Posted by leadgolem
Something like this in the initial script might do it.
Code:
export http_proxy="$http_proxy"
Though I find it odd this variable is in lowercase letters...

EDIT: This also assumes that the "http_proxy" variable is accessible in the initial script. If it is not, then you would want to use something more like this.
Code:
export http_proxy="http://www.proxy.com:8080"
Though that won't help anyone else using a proxy server.
Exactly, so lets see what Duli comes out with so that its usable by all...
Reply With Quote
  #67  
Old 10th March 2008, 09:07 AM
leadgolem Offline
Registered User
 
Join Date: Apr 2005
Location: Littleton, CO
Age: 32
Posts: 2,857
I just had a better idea, write a short if/then to see if the variable exists. If it does run the rpm command with the appropriate options. You should be able to use the variable it's self to configure the rpm command. That is, if the variable is showing up in the subshell at all.
__________________
S.C.O.U.R.G.E. Heroes of lesser renown, contributor.
Reply With Quote
  #68  
Old 10th March 2008, 09:10 AM
bmvbab Offline
Registered User
 
Join Date: Jun 2005
Location: India
Age: 36
Posts: 376
Quote:
Originally Posted by leadgolem
I just had a better idea, write a short if/then to see if the variable exists. If it does run the rpm command with the appropriate options. You should be able to use the variable it's self to configure the rpm command. That is, if the variable is showing up in the subshell at all.
The problem is with the env variable not showing up at all in the new shell.
It does show up when I start a new bash session from inside another by running bash at the CLI. But why does the same not happen in this script?

A friend mentioned that if we use #!/bin/bash it would drop env variables in the new shell. Does that ring any bells? Looks like we would need a wrapper or some config file...I would not like to have one more config file
Reply With Quote
  #69  
Old 10th March 2008, 09:16 AM
leadgolem Offline
Registered User
 
Join Date: Apr 2005
Location: Littleton, CO
Age: 32
Posts: 2,857
could be, #!/bin/sh does behave slightly differently from #!/bin/bash. Let me do a bit of testing...
__________________
S.C.O.U.R.G.E. Heroes of lesser renown, contributor.
Reply With Quote
  #70  
Old 10th March 2008, 09:43 AM
leadgolem Offline
Registered User
 
Join Date: Apr 2005
Location: Littleton, CO
Age: 32
Posts: 2,857
Nope, the behavior doesn't seem to be any different in regards to subshell/session variables...
__________________
S.C.O.U.R.G.E. Heroes of lesser renown, contributor.

Last edited by leadgolem; 10th March 2008 at 09:53 AM.
Reply With Quote
  #71  
Old 10th March 2008, 10:10 AM
leadgolem Offline
Registered User
 
Join Date: Apr 2005
Location: Littleton, CO
Age: 32
Posts: 2,857
I think I have it. I think this script is being run in a normal shell instead of a login shell. That means that it is not loading .bashrc or .bash_profile files from either your user, or root. Hence, as far as it is concerned no http_proxy variable was ever defined for use at all. At the moment, I'm not sure what to do about this though.

That would also explain why running it manually from a terminal works, but running the rpm version doesn't. I think consolehelper is what is giving you a normal shell instead of a login shell. When you run the scripts from a login shell your .bashrc and .bash_profile files are loaded, so the http_proxy variable is defined.

EDIT: Yep, just confirmed that consolehelper does precisely this.
__________________
S.C.O.U.R.G.E. Heroes of lesser renown, contributor.

Last edited by leadgolem; 10th March 2008 at 10:17 AM.
Reply With Quote
  #72  
Old 10th March 2008, 01:14 PM
Duli Offline
Registered User
 
Join Date: Jul 2006
Location: Sao Paulo, SP - Brazil
Age: 37
Posts: 712
bmvbab and leadgolem: Ok, so I think you guys just narrowed the issue. I´ll do some tests with all the provided information and certainly come out with a solution.
Reply With Quote
  #73  
Old 16th March 2008, 09:42 AM
multescugeorge@ Offline
Registered User
 
Join Date: Jun 2005
Posts: 723
EasyLife gets my stamp of approval: (^_^)
__________________
But of course, take the above with a grain of salt...
Reply With Quote
  #74  
Old 20th March 2008, 01:58 PM
karlpiuemeno Offline
Registered User
 
Join Date: Jul 2007
Location: Kernel
Age: 30
Posts: 108
wow, very good project!

My website helps fedora users in installing this extras... but your solution is VERY good... so I wanna do an Italian translation...

can you give me the necessary language files?
Reply With Quote
  #75  
Old 20th March 2008, 11:56 PM
Duli Offline
Registered User
 
Join Date: Jul 2006
Location: Sao Paulo, SP - Brazil
Age: 37
Posts: 712
Quote:
Originally Posted by karlpiuemeno
wow, very good project!

My website helps fedora users in installing this extras... but your solution is VERY good... so I wanna do an Italian translation...

can you give me the necessary language files?
Sure, here is the link to the english file.

Hey, thanks a lot for your efforts!

Duli
Reply With Quote
Reply

Tags
automated, configurations, easylife, fedora, installs

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
What are all the configurations we should change to access interner in fedora 3? rohinvijay Servers & Networking 2 7th January 2009 11:35 AM
Installing java64 using easylife bobo60 Using Fedora 0 28th December 2008 11:18 PM
Help Easylife Installer Dwarflord Installation, Upgrades and Live Media 1 7th October 2008 10:30 PM
easylife doesn't work in Fedora 9 1inxs Alpha - Beta (Fedora 9 Only) 5 18th April 2008 07:01 AM
Keyboard Problem after running EasyLIfe mikefarris Hardware & Laptops 8 23rd March 2008 04:52 AM


Current GMT-time: 12:36 (Monday, 27-03-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat