oddmu-filter(7)

Name

oddmu-filter - keeping subdirectories separate

Description

There are actions such as searching and archiving that act on multiple pages, not just a single page. These actions walk the directory tree, including all subdirectories. In some cases, this is not desirable.

Sometimes, subdirectories are separate sites, like the sites of other projects or different people. Depending on how you think about it, you might not want to include those "sites" in searches or archives of the whole site.

Since directory tree actions always start in the directory the visitor is currently looking at, directory tree actions starting in a "separate site" automatically act as expected. The action is limited to that subdirectory tree.

When visitors look at a page in the "main site", however, directory tree actions must skip any sub directories that are part of a "separate site".

The way to identify separate sites is via the environment variable ODDMU_FILTER. It's value is a regular expression matching separate sites.

Examples

"ODDMU_FILTER=^project/" means that a directory tree action outside the "project/" directory does not include pages in the "project/" directory.

In other words, http://localhost:8080/search/?q=oddmu skips any pages in "project/".

http://localhost:8080/search/?q=oddmu

At the same time, http://localhost:8080/search/project/?q=oddmu works like it always does: search is limited to "project/" and its subdirectories.

http://localhost:8080/search/project/?q=oddmu

Security

If the subdirectory is a private site, then you need to use ODDMU_FILTER to exclude it from directory tree actions in the main site, and you need to configure your web server such that it doesn't allow visitors access to the directory tree without authentication.

See also

oddmu(1), oddmu-search(7), oddmu-apache(5), oddmu-nginx(5)

oddmu(1)

oddmu-search(7)

oddmu-apache(5)

oddmu-nginx(5)

Authors

Maintained by Alex Schroeder alex@gnu.org.

alex@gnu.org