Outside of views and navigation, there are a number of resources that the web application will use. For instance, applications and dashboards can reference CSS and images, as we did in Chapter 8, Working with Apps. These resources are stored under $SPLUNK_HOME/etc/apps/$appname/appserver/. There are a few directories that appear under this directory, as follows:
- static: Any static files that you would like to use in your application are stored here. There are a few magic documents that Splunk itself will use, for instance, appIcon.png, screenshot.png, application.css, and application.js. Other files can be referenced using includes or templates. See the Using ServerSideInclude in a complex dashboard section in Chapter 8, Working with Apps, for an example of referencing includes and static images.
- event_renderers: Event renderers allow you to run special display code for specific event types. We will write an event renderer in Chapter 13, Extending Splunk.
- templates: It is possible to create special templates using the mako template language. It is not commonly done.
- modules: This is where new modules that are provided by apps are stored. Examples of this include the Google Maps and Sideview Utils modules. See https://dev.splunk.com for more information about building your own modules, or use existing modules as an example.