anchor.diff:  
     extraConfig =
       ''
  -      ${if config.urlPrefix != "" then "Alias ${config.urlPrefix} ${pkgs.owncloud}" else ''
  +      ${if config.urlPrefix != "" then "Alias ${config.urlPrefix} ${config.package}" else ''
   
           RewriteEngine On
           RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-f
           RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-d
         ''}
   
  -      <Directory ${pkgs.owncloud}>
  -        ${builtins.readFile "${pkgs.owncloud}/.htaccess"}
  +      <Directory ${config.package}>
  +        ${builtins.readFile "${config.package}/.htaccess"}
         </Directory>
       '';
   
  
positive.code:     { name = "OC_CONFIG_PATH"; value = "${config.dataDir}/config/"; }
    ];
  
    documentRoot = if config.urlPrefix == "" then pkgs.owncloud else null;
  
    enablePHP = true;
  
    options = {
  
      urlPrefix = mkOption {
        default = "";
  
negative.code:       ${pkgs.sudo}/bin/sudo -u postgres ${pkgs.postgresql}/bin/psql -h "/tmp" -U postgres -d ${config.dbName} -Atw -c "$QUERY" || true
      fi
  
      if [ -e ${config.package}/config/ca-bundle.crt ]; then
        cp -f ${config.package}/config/ca-bundle.crt ${config.dataDir}/config/
      fi
  
      ${php}/bin/php ${config.package}/occ upgrade >> ${config.dataDir}/upgrade.log || true
  
      chown wwwrun:wwwrun ${config.dataDir}/owncloud.log || true
  
  