LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 02-07-2011, 06:47 PM   #1
cuco76
Member
 
Registered: Oct 2003
Location: Tucson
Distribution: Fedora, RHEL, Ubuntu
Posts: 225

Rep: Reputation: 31
export proxy via profile.d


So I've always added an export line in the /etc/profile that has the proxy server for our organization. Now there is a warning in that file that I should use a custom .sh in the profile.d folder. Can I just create a myproxy.sh with the export http_proxy="insert my proxy" line in it and call it a day or do I have to do some crazy shell script?

Any assistance would be appreciated!

Thanks,
 
Old 02-07-2011, 07:43 PM   #2
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
Yes you can - on my system, the files in /etc/profile.d all have a mode of 0755 (rwxr-xr-x) and are owned by root. As an example, here is /etc/profile.d/jdk.sh:
Code:
ls -l /etc/profile.d/jdk.sh 
-rwxr-xr-x 1 root root 148 2010-05-09 11:47 /etc/profile.d/jdk.sh

cat /etc/profile.d/jdk.sh 
#!/bin/sh
export JAVA_HOME=/usr/lib64/java
export MANPATH="${MANPATH}:${JAVA_HOME}/man"
export PATH="${PATH}:${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin"
 
Old 02-08-2011, 07:42 PM   #3
cuco76
Member
 
Registered: Oct 2003
Location: Tucson
Distribution: Fedora, RHEL, Ubuntu
Posts: 225

Original Poster
Rep: Reputation: 31
Thank you very much. I will look at that first thing tomorrow!
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
export proxy on Gentoo (virtual machine) LoDam Linux - Newbie 2 02-04-2011 03:29 AM
export proxy setting permanently Isix Linux - Newbie 2 01-11-2009 02:37 AM
Export proxy settings nitrohuffer2001 Linux - General 4 10-18-2006 11:05 AM
PATH export in etc/profile.local adds dir twice tongar Linux - Newbie 3 06-16-2005 03:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 02:01 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration