/**
  * Create capsule symlinks
  *
  * @param string $source      The instance source
  * @param string $destination The destination
  * @param string $storage     The storage path to link
  *
  * @return bool
  */
 protected function createCapsuleLinks($source, $destination, $storage)
 {
     $_links = config('capsule.instance.symlinks', []);
     //  Create symlinks
     foreach ($_links as $_link) {
         $_linkTarget = 'storage' == $_link ? Disk::path([$storage, InstanceStorage::getStoragePath($this->instance)]) : Disk::path([$source, $_link]);
         $_linkName = Disk::path([$destination, $_link]);
         if (!file_exists($_linkName) || $_linkTarget != readlink($_linkName)) {
             if (false === symlink($_linkTarget, $_linkName)) {
                 $this->error('Error symlinking target "' . $_linkTarget . '"');
                 return false;
             }
         }
     }
     //  Create the bootstrap[/cache] directory
     $_sourcePath = Disk::path([$source, 'bootstrap']);
     $_bootstrapPath = Disk::path([$destination, 'bootstrap'], true);
     //  Ensure the cache directory is there as well...
     Disk::path([$_bootstrapPath, 'cache'], true);
     $_files = Disk::glob($_sourcePath . DIRECTORY_SEPARATOR . '*', GlobFlags::GLOB_NODIR | GlobFlags::GLOB_NODOTS);
     foreach ($_files as $_file) {
         if (false === copy($_sourcePath . DIRECTORY_SEPARATOR . $_file, $_bootstrapPath . DIRECTORY_SEPARATOR . $_file)) {
             $this->error('Failure copying bootstrap file "' . $_file . '" to "' . $_bootstrapPath . '"');
             return false;
         }
     }
     return true;
 }