Files configuration

Swarm can be customized using the following config items:

Tip

If you make a configuration change, Swarm will not use it until the configuration cache has been reloaded, this forces Swarm to use the new configuration. You must be an admin or super user to reload the Swarm config cache. Navigate to the User id dropdown menu, select System Information, click the Cache Info tab, and click the Reload Configuration button.

max_size

Swarm limits the size of files that are displayed in a review or standard file view. This defaults to 1MB, but can be configured to be larger or smaller. Files larger than this will be truncated.

If the value is set to zero, then the file size is unlimited.

<?php
// this block should be a peer of 'p4'
'files' => array(
'max_size' => 1 * 1024 * 1024, // 1MB (in bytes)
),

download_timeout

When downloading files, there is a timeout which defaults to 30 minutes. This can be changed by setting the download_timeout configurable to a value in seconds. Alternatively, setting it to zero removes the timeout.

<?php
// this block should be a peer of 'p4'
'files' => array(
'download_timeout' => 1800, // seconds (30 minutes)
),

allow_edits

By default, you can edit a file from the files page and shelve or commit it.

When set to false, files cannot be edited from the Swarm files page.

<?php
// this block should be a peer of 'p4'
'files' => array(
'allow_edits' => false, // default is true
),