prisme-flow
Version:
prisme platform flow engine
80 lines (74 loc) • 2.96 kB
HTML
<!--
Created by prisme.io on 09/06/2017.
@author <a href="mailto:hello@prisme.io">savane vamara</a> (prisme.io)
-->
<script type="text/javascript">
RED.nodes.registerType('ftp-server', {
category: 'input',
color: '#f37a33',
defaults: {
name: {value: ''},
port: {value: 7021}
},
credentials: {
username: {type: 'text'},
password: {type: 'password'}
},
inputs: 0,
outputs: 1,
icon: 'ftp.png',
label: function () {
return this.name || 'ftp server';
},
paletteLabel: 'ftp server',
align: 'left'
});
</script>
<script type="text/x-red" data-template-name="ftp-server">
<div class="form-row">
<label for="node-input-name"><i class="icon-tag"></i> Name</label>
<input type="text" id="node-input-name" placeholder="Name">
</div>
<div class="form-row">
<label for="node-input-port"><i class="icon-tag"></i>Port</label>
<input type="number" id="node-input-port" placeholder="">
</div>
<div class="form-row">
<label for="node-input-username"><i class="icon-tag"></i>Username</label>
<input type="text" id="node-input-username" placeholder="">
</div>
<div class="form-row">
<label for="node-input-password"><i class="icon-tag"></i>Password</label>
<input type="password" id="node-input-password" placeholder="">
</div>
</script>
<script type="text/x-red" data-help-name="ftp-server">
<!-- START -->
<h1 id="ftp-server">FTP Server</h1>
<p>FTP Server for prisme-flow that currently only supports putting files.
Uploaded files are emitted from this node via<br><code>msg.payload</code> of type Buffer.</p>
<p>Written for my Dad so he can wire his IP camera's motion detection directly into prisme-flow. </p>
<h1 id="installation">Installation</h1>
<pre><code>$ cd ~/.prisme-flow
</code></pre><h1 id="configure-node-red">Configure prisme-flow</h1>
<p>Drag the FTP Server node into your workspace and double click to configure:</p>
<ul>
<li>Enter a free port on your prisme-flow server</li>
<li>Enter a username of your choosing</li>
<li>Enter a password of your choosing</li>
</ul>
<h1 id="configure-a-device-to-use-your-node-red-ftp-server">Configure a device to use your prisme-flow FTP server</h1>
<p>Here's an example of configuring a Foscam IP camera to upload images into prisme-flow:</p>
<ul>
<li>Enter the IP address of your Node-RED server as the FTP server address</li>
<li>Enter the port, username and password that you chose when you configured the FTP node in prisme-flow above.</li>
</ul>
<p>Now you can configure the motion settings of your IP camera to upload images to FTP. </p>
<p>The images are then emitted from this node as a buffer via <code>msg.payload</code>.</p>
<h1 id="todo">TODO</h1>
<ul>
<li>TLS support</li>
<li>Proper testing</li>
</ul>
<!-- END -->
</script>