hlx-webdav-push
A writable stream to send HLS streams to an external WebDAV server
Features
- Being used with other
hlx
objects, it provides a functionality to send every HLS related data (playlist and segments) to an external webdav endpoint.
Install
Usage
const hlx = ;const createWriteStream = ; const webdav = ; // Send files to an external webdav endpointhlx;
API
The features are built on top of the Node's transform streams.
createWriteStream(options)
Creates a new TransformStream
object.
params
Name | Type | Required | Default | Description |
---|---|---|---|---|
options | object | Yes | N/A | See below |
options
Name | Type | Default | Description |
---|---|---|---|
url | string | N/A | URL of the destination (webdav server endpoint) |
user | string | N/A | Basic auth user name |
pass | string | N/A | Basic auth password for the server |
digest | boolean | false | If true and user/pass are both specified, digest-based authentication will be enabled |
token | object | N/A | An object holding Access Token parameters issued by OAuth 2.0 auth server. Client must specify either token or user /path . token is ignored when user /pass are present. |
inputDir | string | / | The root directory from which all the files are read (This option is only used in case of file urls) |
concurrency | number | 6 | Max number of requests concurrently sent |
agent | http.Agent | undefined | Proxy agent |
return value
An instance of TransformStream
.