FTP Deployment Handler

Handles the deployment of one or more Deployment Packages to an SFTP or FTP server.

The remote S/FTP server is described by a URL, username and password.

The contents of the Deployment Packages will be deployed sequentially to the target location. If any of the content within the Deployment Packages fails to copy, it will simply be skipped. Other content objects will be allowed to proceed unabated.

Configuration

{
    "url": "{url}",
    "username": "{username}",
    "password": "{password}"
}

Where url is the remote address of the server and username and password describe the connection credentials.

Mappings

The FTP Deployment handler respects the f:deployment-config feature if applied to a node. This feature lets you configure a set of mappings that determine how a node's JSON object and any binary attachments should be mapped down and written to disk.

The default mappings are:

[{
    "type": "object-to-file",
    "config": {
        "filepath": "//.json"
    }
}, {
    "type": "attachment-to-file",
    "config": {
        "attachmentId": "*",
        "filepath": "//"
    }
]

These default mappings make it so that your Node's JSON is written to disk along with any of its attachments.

  • Nodes are written to disk like this:

    /{nodeId}/node.json

  • Node attachments are written as well, like this:

    /{nodeId}/attachments/{attachmentId}.{ext}

  • Associations are written to disk like this:

    /{associationId}/association.json

  • Association attachments are written as well, like this:

    /{associationId}/attachments/{attachmentId}.{ext}

Example

{
    "url": "ftp://myserver:21",
    "username": "inigo",
    "password": "montoya"
}