in reply to Executing unix command from script

You can configure sudo so that it doesn't ask for a password when executing particular commands. Note that is a huge security hole if done wrong.

See man 5 sudoers for a description of the configuration file syntax.