summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authororbiter <mc@yacy.net>2014-08-26 19:02:53 +0200
committerorbiter <mc@yacy.net>2014-08-26 19:02:53 +0200
commitb3ebd38079eb21fe0458be81fcdae6dfd25c49a5 (patch)
tree66f54b1301ee7475dbc52075e24642d277ad4e0c
parent5611d45b65f035da0d2d783ff37ef52033655f23 (diff)
removed the HTDOCS repository concept because the concept to host files
on the YaCy http server is obsolete; YaCy can index file:// and smb:// paths
-rw-r--r--defaults/yacy.init8
-rw-r--r--htroot/ConfigBasic.html5
-rw-r--r--htroot/ConfigBasic.java7
-rw-r--r--source/net/yacy/server/http/HTTPDFileHandler.java6
4 files changed, 1 insertions, 25 deletions
diff --git a/defaults/yacy.init b/defaults/yacy.init
index dfa810e9e..41ccdaa1e 100644
--- a/defaults/yacy.init
+++ b/defaults/yacy.init
@@ -207,14 +207,6 @@ htDefaultPath=htroot
# the htdocs path shares its content with the htroot path
htDocsPath = DATA/HTDOCS
-# alternative path for the repository path of the web server: the URL
-# http://localhost:8090/repository
-# points to DATA/HTDOCS/repository, but can be altered with this repository path
-# hint: the repository path is the default path for intranet indexing. The easiest ways
-# to do a indexing of the local storage system is to set a path here for the repository
-# that points to the root path of the files that shall be indexed
-repositoryPath=DATA/HTDOCS/repository
-
# the default files (typically index.html), if no file name is given
# The complete path to this file is created by combination with the rootPath
# you can set a list of defaults, separated by comma
diff --git a/htroot/ConfigBasic.html b/htroot/ConfigBasic.html
index e1dd10e88..0e86b611a 100644
--- a/htroot/ConfigBasic.html
+++ b/htroot/ConfigBasic.html
@@ -63,10 +63,7 @@
<tr>
<td valign="top"><label for="usecaseFreeworld">Join and support the global network 'freeworld', search the web with an uncensored user-owned search network</label></td>
<td valign="top"><label for="usecasePortal">Your YaCy installation behaves independently from other peers and you define your own web index by starting your own web crawl. This can be used to search your own web pages or to define a topic-oriented search portal.</label></td>
- <td valign="top"><label for="usecaseIntranet">Create a search portal for your intranet or web pages or your (shared) file system. URLs may be used with http/https/ftp and a local domain name or IP, or with an URL of the form file:///&lt;path&gt; or smb://&lt;server&gt;/&lt;path&gt;<br/>
- Files may also be shared with the YaCy server, assign a path here:
- <input type="text" name="repositoryPath" size="37" value="#[repositoryPath]#" /><br/>
- This path can be accessed at <a href="http://localhost:#[port]#/repository/">http://localhost:#[port]#/repository</a></label>. Use that path as crawl start point.
+ <td valign="top"><label for="usecaseIntranet">Create a search portal for your intranet or web pages or your (shared) file system. URLs may be used with http/https/ftp and a local domain name or IP, or with an URL of the form file:///&lt;path&gt; or smb://&lt;server&gt;/&lt;path&gt;<br/>
</td>
</tr>
</table>
diff --git a/htroot/ConfigBasic.java b/htroot/ConfigBasic.java
index 7612a1816..577fa1968 100644
--- a/htroot/ConfigBasic.java
+++ b/htroot/ConfigBasic.java
@@ -211,13 +211,6 @@ public class ConfigBasic {
sb.setConfig(SwitchboardConstants.SEARCH_VERIFY, "cacheonly"); // nocache,iffresh,ifexist,cacheonly,false
sb.setConfig(SwitchboardConstants.SEARCH_VERIFY_DELETE, "false");
}
- if ("intranet".equals(post.get("usecase", ""))) {
- final String repositoryPath = post.get("repositoryPath", "/DATA/HTROOT/repository");
- final File repository = ((repositoryPath.length() > 0 && repositoryPath.charAt(0) == '/') || (repositoryPath.length() > 1 && repositoryPath.charAt(1) == ':')) ? new File(repositoryPath) : new File(sb.getDataPath(), repositoryPath);
- if (repository.exists() && repository.isDirectory()) {
- sb.setConfig("repositoryPath", repositoryPath);
- }
- }
}
networkName = sb.getConfig(SwitchboardConstants.NETWORK_NAME, "");
diff --git a/source/net/yacy/server/http/HTTPDFileHandler.java b/source/net/yacy/server/http/HTTPDFileHandler.java
index 6494f3d3b..68879f418 100644
--- a/source/net/yacy/server/http/HTTPDFileHandler.java
+++ b/source/net/yacy/server/http/HTTPDFileHandler.java
@@ -101,10 +101,6 @@ public final class HTTPDFileHandler {
if (!(htDocsPath.exists())) htDocsPath.mkdirs();
}
- // create a repository path
- final File repository = new File(htDocsPath, "repository");
- if (!repository.exists()) repository.mkdirs();
-
// create htLocaleDefault, htLocalePath
if (htDefaultPath == null) htDefaultPath = theSwitchboard.getAppPath("htDefaultPath", SwitchboardConstants.HTROOT_PATH_DEFAULT);
if (htLocalePath == null) htLocalePath = theSwitchboard.getDataPath("locale.translated_html", "DATA/LOCALE/htroot");
@@ -123,8 +119,6 @@ public final class HTTPDFileHandler {
* @param path relative from htroot */
public static File getLocalizedFile(final String path){
String localeSelection = switchboard.getConfig("locale.language","default");
- if (path.startsWith("/repository/"))
- return new File(switchboard.getConfig("repositoryPath", "DATA/HTDOCS/repository"), path.substring(11));
if (!(localeSelection.equals("default"))) {
final File localePath = new File(htLocalePath, localeSelection + '/' + path);
if (localePath.exists()) return localePath; // avoid "NoSuchFile" troubles if the "localeSelection" is misspelled