Difference between revisions of "Automount a network drive"

From AwkwardTV
Jump to: navigation, search
(New page: First, thanks to Azral ! The solution is to create a startupitem in /Library/StartupItems/ First of - create a catalog (in this case named "MountShit" but a name of your c...)
 
Line 3: Line 3:
 
The solution is to create a startupitem in /Library/StartupItems/
 
The solution is to create a startupitem in /Library/StartupItems/
  
First of - create a catalog (in this case named "MountShit" but a name of your choosing chould suffice - rename files/parameters if you change name) containing two files:
+
First of - create a catalog (in this case named "MountStuff" but a name of your choosing chould suffice - rename files/parameters if you change name) containing two files:
  
File MountShit containing:
+
File MountStuff containing:
  
 
<pre>
 
<pre>
Line 16: Line 16:
  
 
{
 
{
   Description = "MountShit";
+
   Description = "MountStuff";
 
   Provides = ("Mounts");
 
   Provides = ("Mounts");
 
   Requires = ("Network");
 
   Requires = ("Network");
Line 23: Line 23:
 
</pre>
 
</pre>
  
Don't forget to sudo chmod +x MountShit. (:
+
Don't forget to sudo chmod +x MountStuff. (:
  
 
And thats about it! Now it mounts my share(s) on startup.
 
And thats about it! Now it mounts my share(s) on startup.

Revision as of 11:21, 7 July 2007

First, thanks to Azral !

The solution is to create a startupitem in /Library/StartupItems/

First of - create a catalog (in this case named "MountStuff" but a name of your choosing chould suffice - rename files/parameters if you change name) containing two files:

File MountStuff containing:

#!/bin/sh
/usr/sbin/shlight '//Storage/DISK 2' /Users/frontrow/Movies/disk -U pcguest -P pcguest 

File StartupParameters.plist containing:


{
  Description = "MountStuff";
  Provides = ("Mounts");
  Requires = ("Network");
  OrderPreference = "None";
}

Don't forget to sudo chmod +x MountStuff. (:

And thats about it! Now it mounts my share(s) on startup.