Beispiel #1
0
 /**
  * Used by the sync task
  *
  * @param string $path
  * @return \DNEnvironment
  */
 public static function create_from_path($path)
 {
     $e = DNEnvironment::create();
     $e->Filename = $path;
     $e->Name = basename($e->Filename, '.rb');
     // add each administrator member as a deployer of the new environment
     $adminGroup = Group::get()->filter('Code', 'administrators')->first();
     $e->DeployerGroups()->add($adminGroup);
     return $e;
 }