Need to use 'sudo' in an installer script
Need to use 'sudo' in an installer script
- Subject: Need to use 'sudo' in an installer script
- From: Brian Weitzner <email@hidden>
- Date: Fri, 29 Dec 2006 19:25:45 -0500
Hi, I am new to PackageMaker and this list. I am writing a database app that I need to create the database in a preinstall script. In order to do this, I need to check if the database server is running and start it if it is not. However, you need administrative rights to start the database. The commands
sudo /Library/StartUpItems/MySQLCOM/MySQLCOM start or sudo /usr/local/mysql/support-files/mysql.server start
work just fine for this, but a password is needed. How can I get the installer to use the user's password to do this? Or is there another way to do this that would not require using "sudo?" Thanks! |
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden