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

Notices


Reply
  Search this Thread
Old 11-11-2008, 09:00 AM   #1
irishbitte
Senior Member
 
Registered: Oct 2007
Location: Brighton, UK
Distribution: Ubuntu Hardy, Ubuntu Jaunty, Eeebuntu, Debian, SME-Server
Posts: 1,213
Blog Entries: 1

Rep: Reputation: 88
script to copy configuration folder to all users


Hi folks, back again with more problems!

I want to set up a situation where all users will have the same config for a particular web browser.

This is as far as I have gotten, any help anyone can give me would be most appreciated!

Code:
# Bash script to copy .opera folder to all users home directories

# Become root:

sudo -s

# Change to home directory

cd /home/

# For every user, remove current opera config, and install new one:

for $USER in home
	do 

	#remove current config file:

	rm -r .opera/

	#Copy in new config file

	cp /home/sysadmin/config_files/.opera /home/$USER/

	# Change ownership of folder to USER

	chown -R $USER:$USER /home/$USER/.opera
Any improvements or insights anyone can offer will be really appreciated!
 
Old 11-11-2008, 09:10 AM   #2
vladmihaisima
Member
 
Registered: Oct 2002
Location: Delft, Netherlands
Distribution: Gentoo
Posts: 196

Rep: Reputation: 33
Maybe describe more why you want to have the same configuration ? Will you do this regulary ? Shouldn't they change anything ? Your script works fine if you want a script to copy the configurations to their home, but maybe you want something else or something more/
 
Old 11-11-2008, 09:59 AM   #3
irishbitte
Senior Member
 
Registered: Oct 2007
Location: Brighton, UK
Distribution: Ubuntu Hardy, Ubuntu Jaunty, Eeebuntu, Debian, SME-Server
Posts: 1,213

Original Poster
Blog Entries: 1

Rep: Reputation: 88
Hi vladmihaisima,

More simply, I want to use opera as a browser that only goes to one website, so I want to set the configuration globally. This seems like the easiest way to accomplish this! What do you think?
 
Old 11-12-2008, 06:02 AM   #4
vladmihaisima
Member
 
Registered: Oct 2002
Location: Delft, Netherlands
Distribution: Gentoo
Posts: 196

Rep: Reputation: 33
If you want them to have some website the first time they open the browser, I think it works...

If you want them to access JUST one website, I do not think it will work. My first idea would be to use some kind of restricted proxy server, but I have no experience with this.
 
  


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
Create script in CentOS4 to copy folder but promt user to enter name of destination mastermindpr Linux - General 2 02-08-2006 10:45 AM
perl script help required to create users and changing the owner to pericular folder sridhar11 Programming 2 10-25-2005 02:16 PM
starting script, init by copy/create file in (samba) folder? muab Linux - General 7 06-22-2005 06:02 PM
How to copy in a script files to a samba folder? Julianus Linux - Networking 1 10-09-2004 07:29 PM
writing a script to perform a function on each users mail folder jhill Linux - Newbie 2 08-24-2004 07:18 AM

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

All times are GMT -5. The time now is 03:04 AM.

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