-
Notifications
You must be signed in to change notification settings - Fork 37
Getting Started
More detailed instructions for installing and setting up diskover-web can be found on the diskover wiki install guide.
- Install application dependencies using php composer (you will need to install composer first if you don't already have it, install with apt or yum or instructions here https://getcomposer.org/)
$ cd diskover-web
$ composer install
- Copy .sample files
Copy diskover-web settings file (Constants.php) and other .sample files and adjust for your environment. Set these files to have r/w permissions for the user running your web server.
$ cd diskover-web
$ cp src/diskover/Constants.php.sample src/diskover/Constants.php
$ cp public/smartsearches.txt.sample public/smartsearches.txt
$ cp public/customtags.txt.sample public/customtags.txt
$ cp public/extrafields.txt.sample public/extrafields.txt
$ cp public/costanalysis.txt.sample public/costanalysis.txt (Enterprise only)
Most important is setting the ES_HOST to the hostname or ip of your ES server unless it is running on the same host as diskover-web. The rest of the default settings should work fine unless you are using AWS Elasticsearch or are using a different port for Elasticsearch other than the default of 9200.
Change the default login username/password
Your login will expire after 60 min if no activity. You can also choose to disable logins. (the default)
<?php
namespace diskover;
class Constants {
// set to your Elasticsearch host or ip, if you are using AWS set to your endpoint without http:// or https://
const ES_HOST = 'localhost';
//const ES_HOST = 'search-diskover-testing-5koltvn6cb3scqhwd7jploobfq.ap-northeast-1.es.amazonaws.com';
// set to your Elasticsearch port, default 9200, if you are using AWS set to 443 or 80
const ES_PORT = 9200;
//const ES_PORT = 443;
// set to TRUE if using AWS ES
const AWS = FALSE;
// set to TRUE if using AWS ES and HTTPS, FALSE FOR HTTP
const AWS_HTTPS = TRUE;
// set following two lines if using X-Pack http-auth
const ES_USER = '';
const ES_PASS = '';
// login auth for diskover-web
const LOGIN_REQUIRED = FALSE;
const DISKOVER_USER = 'diskover';
const DISKOVER_PASS = 'darkdata';
// diskover.py socket listener server
const ENABLE_SOCKET_CLIENT = FALSE;
const SOCKET_LISTENER_HOST = '127.0.0.1';
const SOCKET_LISTENER_PORT = 9999;
// default min file size (bytes) filter
const FILTER = 1;
// default mtime filter
const MTIME = 0;
// default maxdepth filter
const MAXDEPTH = 2;
// default don't use count (use size)
const USE_COUNT = 0;
// default show files on analytics pages
const SHOW_FILES = 1;
// default hide threshhold filter
const HIDE_THRESH = 0.9;
// default results per search page
const SEARCH_RESULTS = 50;
}
- Create index.php symlink.
$ cd public
$ ln -s dashboard.php index.php
- Start diskover web using PHP's built-in web server (For best performance and production use, you should set up Nginx or Apache and php-fpm (fastcgi))
$ cd public
$ php -S <IP>:8000
By default diskover web will communicate with the Elasticsearch API at http://<ES_HOST>:9200
. If you are running ES on a different port than default 9200, you will need to change config file or pass this information to diskover web when starting it up via an environment variable:
$ APP_ES_PORT=<PORT> php -S <IP>:8000
You can also change the index(s) used this way:
$ APP_ES_INDEX=<INDEX> php -S <IP>:8000
APP_ES_INDEX2 for index2.
If no indices are set as args, you will have the option to pick your indices when you open the dashboard page. You can change your indices after on the Admin page, in the url variables (index and index2) or by removing diskover cookies.
- Open your web browser and visit
http://<IP>:8000
. The default login is diskover / darkdata.
- Supported browsers are Chrome and Safari
- Cookies are required
- If any analytics pages are not loading (black screen, etc), please whitelist the site in any Adblock and security browser plugins you are running.