pckg_expires_index_gone

The `pckg_expires_index_gone` directive specifies whether to set a response header when a requested index file is not found.

Syntaxpckg_expires_index_gone on | off;
Defaultoff
Contexthttp, server, location
Arguments1

Description

The pckg_expires_index_gone directive is used in the Kaltura Media Framework's NGINX module to control the behavior of the server when an expired index file is requested but does not exist. When enabled (set to 'on'), this directive sends a response indicating that the index is gone, which can be useful in informing clients of the unavailability of a requested resource. This can be particularly advantageous in media applications where the absence of an index file can signify that content is no longer accessible.

The directive operates within http, server, and location contexts, allowing for granular control over its application depending on the hierarchy of the configuration. Setting the directive affects not only the HTTP response codes but can also provide specific handling instructions for clients, enabling them to appropriately respond to the missing resources. The primary argument passed to the directive is a boolean value, allowing it to be easily toggled between enabled and disabled states.

It's important to note that if this directive is not set, NGINX will follow its default behavior for handling non-existent index files, which may not provide the desired client messaging regarding missing resources. Proper configuration of the pckg_expires_index_gone directive can enhance user experience and application reliability.

Config Example

server {
    location /media/ {
        pckg_expires_index_gone on;
    }
}

Ensure that the directive is set in the correct context (http, server, location) for it to take effect.

Remember to handle client responses appropriately in the application logic when an index file is deemed 'gone'.

Overuse of this directive without proper error handling may lead to confusion for users accessing expired content.

← Back to all directives