Loading...
 

fauSendFile

The fauSendFile OCE app provides for the automatic sending of a file placed into a monitored directory.

Install:Local/Remote
Run Support:Single member

App Downloads

Operational Overview

Highlights for the fauSendFIle functionality are as follows:

Recursive Monitoring
Any file placed anywhere in the top level directory, or it's subdirectories, will be sent to designated recipient(s).
Config Files
Configuration files can be placed in any directory of the monitored tree to define sending instructions specific to that directory.
Global Defaults
Global defaults can be set through the OCE app management screen to define global default behaviours for when no directory specific configuration file is available.
Image Resizing
Images discovered in the fauSendFile monitored directories will be automatically resized as specified by configuration details before being sent.


The fauSendFile application routing can be further tailored through the use of Fautore Instructions. An example workflow would be that of setting up an instruction trigger so that if a USDS message comes in from a specific tribe member using fauSendFile that the message automatically will be directed to one or more locations. This strategy allows for message routing without ever setting up a directory specific configuration file.

Note
The Fautore applications will have different suffixes, or even none at all, depending on the OS for which it is intended. All references to an app in this documentation will normally be by the filename alone for simplicity sake. Please use the below table to derive the exact command you should use:
Suffix OS Comments
app Unix/Linux Distributions specific to Unix and Unix-like OS'es will have no suffix at all. Just use the command as it appears.
app.pl All The perl native installation versions run on all OS'es with Perl support. That is most all OS'es and Windows with augmented support added.
app.exe Windows Distributions specific to Windows platforms will be delivered with an "exe" suffix.

CPAN Dependencies

These download dependencies are required only when running the native perl version of this app.

  1. sudo cpan install File::Type
  2. sudo cpan install Test::JSON
  3. sudo cpan install File::HomeDir
  4. sudo apt-get install perlmagick (LinuxMint distros way to install ImageMagick for perl)
  5. sudo cpan install Net::Address::IP::Local

Environment Dependencies

Variable Disp Default __Description
SF_APPLOC opt program absolute path Defines the home directory for the application. This value acts as the base value for the logging and configuration file locations if no environment variable or options are set.
SF_CONFIG opt {program absolute path}/{appName}.cfg Defines the full path for the configuration file, including the filename to be used.
SF_LOG opt program absolute path Path to create a "log" subdirectory and populate it with log files.

Installation

The fauSendFile program is designed to work on any computer in the POD. It is not a requirement it be installed on the same server as the OCE. See "Example Installations" below for considerations for different ways to install this application.

  1. Download the latest release of fauSendFile
  2. Open the archive using method applicable to your OS
  3. Run the install program provided with your download
./install -c {Fautore Location}

where:

The "Fautore Location" is the top level directory where your Fautore installation files reside. This is not necessarily a full Fautore OCE installation home. On devices remote from the main OCE this will be home only to installed OSA compliant applications.

The '-c' option forces the creation of missing directories. It is not necessary if all directories are known to exist.

use of the './' in front of the 'install' command is highly recommended to ensure the correct install command is run.

Registration

The fauSendFile app is registered to the OCE via command line.

{OCE home}/apps/fauSendFile/fauSendFile [-i,-p,-s,-vp] -r <membername>:<OCE>:<Port>

where:

{OCE home}
the top level directory for the location Fautore files are installed. This is not necessarily a full OCE installation, but only where the OCE related files, like apps, are located.
<membername>
the login name of a local POD member authorized to register applications.
<OCE>
the IP address of the target OCE intended to manage messages from this app.
<Port>
the port of the target OCE intended to manage messages from this app.

Command Options

All options to the fauSendFile command are for use only at registration time. They have no effect other than when registering the app with the OCE.

Option Default Description
-a OCE Net Specify the IP address that should be referenced by the OCE when contacting this app. The default is the IP address of the local computer that communicates with the OCE. This option is useful for when the fauSendFile app is behind a NAT'ed firewall from the OCE and the external addresses is port forwarded to the local address.
Warning: Do not use this option to port forward traffic off the Internet. This option is meant to resolve problems that arise with more complicated intranets. Only use with '-r' option.
-al program absolute path Defines where the application is physically installed and acts as the base directory for logging and configuration files. This option take precedence over the FS_APPLOC environment variable.
-c {program absolute path}/{appName}.cfg The full path of the configuration file to be used including the file name. This option override the value of the SF_CONFIG environment variable.
-h NA Provide a help overview from the command line.
-i 60 Defines the interval in seconds at which the OCE checks to see if messages are available for this app and passes any discovered messages back to the app. Only use with '-r' option.
-l program absolute path Defines the directory for logging. A "log" subdirectory will be created at the location specified.
-p 42777 A valid port number on which the app listens for OCE communications. (1025-65535) Only use with '-r' option.
-r N/A OCE connect string on local network in the form of: ::
This option is only to be used to register apps on the local network.
-s undef If specified the OCE will assume control of starting and stopping the app. Only use this option for installations to the same server as the OCE itself. The OCE cannot manage apps that are remotely installed. Only use with '-r' option.
-t NA Record the time it takes to send individual files to the OCE. Includes file size.
-v NA Display application version.
-vp undef The "Visible Password" option that shows the password being typed in response to the "Password" prompt presented once the registration begins. Only use with '-r' option.

Action Commands

runRun the program for one iteration.
startStart the server to run continuously in the foreground.
daemonSteve the server to run continuously in the background.
stopStop the server
restartStop server (if it was running) and then start it

Examples

fauSendFile run
Runs through all checks once and quit.
fauSendFile start
Starts the program and monitors continuously. This command does not release the command line and cannot be killed with a "^C" keystroke set. Use "fauSendFile stop" from a second terminal to stop the program.
fauSendFile daemon
Just like "fauSendFile start" above except the command line is released and the program runs in the background. Use this command for start scripts and other automated approaches to program startup.
fauSendFile stop
Use this command to stop a fauSendfile program that is perpetually running using either a "start" or "daemon" command.
faSendFile restart
Equivalent to: "fauSendFile stop" then "fauSendFile daemon" and can be used as a direct equivalent to "fauSendFile daemon" with the added benefit of making sure fauSendFile isn't already running.

OCE Managed Configuration Items

The below table describes the configuration items available in the "App Specs" screen of the OCE for this app. The values defined here act as defaults for all discovered files being sent by the app and can be overridden by configuration files local to the directory where the file was found.

Field Type Default Decription
Source Dir string {osSpec}/oceFilePort The top level directory where the app begins looking for files to send via OCE, where {osSpec} represents either the home directory of the account running fauSendFile or the "Documents" directory of the registering member. Which of these locations is defined is OS specific.
Default Image Size size spec 640x480 The maximum size at which images will be sent. The sizing feature of the app will be applied to any file with a mime type of "image". Parameter is specified as WxH.
Default Recipients string OCE Specific The default will be to handle delivery as is customary for the OCE to handle messages containing files passed by this app as it would any message that had no recipient defined. For the Fautore OCE this is to deliver the message as if "ALL" were defined for the message. That means that for the Fautore OCE messages without a defined recipient will be sent to all locally registered tribe members per their respective recipient app default preference.
Delete on Success binary yes If defined the file being sent will be deleted after being received by the OCE. The app does not wait for guarantees from all recipients that the file is received. Sending OCE acceptance is sufficient to delete the file.
Default Summary string varies The default file description summary defined will be sent with any file that doesn't have one specifically defined.
Default Detail string varies The default file description detail defined will be sent with any file that doesn't have one specifically defined.
Inbound Location string {Source Dir}/InDock The location to which all received files are delivered.

App Specific Features

The features listed here are specific to the operation of the fauSendFile app.

Config Files

fauSendFile can make use of configuration files that can exist in any directory that files to be sent are found. The configuration files are directory specific and have no effect on files outside the directory in which the file is found.

  • The config file has different parameters depending on if it is found in the outbound or inbound directory.
  • The config file can can be either of two names regardless of whether it is found in an outbound or inbound directory.
    • The name chosen has no affect on functionality.
    • The name chosen does not have to be consistent across directories
    • The configuration name chosen must be either:
      • .fSF
      • .fauSendFile
  • Unrecognized parameters are ignored. (This means that a single config file template can be used for both inbound and outbound processing and tailored to directory needs)
  • The config file settings do not cascade in their value settings. Lower level directories are not affected by higher level config files.
  • Configuration file entry format is a simple: {item}={value}
    • Example: DefSumm=Sarah Wrestlequeen Photo of the Day
  • Lines with comments begin with a pound (#) sign.
    • Example: # This is a comment
  • Comments line must begin with comments. In-line comments won't work as expected.
    • Example: DefDetail= Some long text # You're in for a surprise with this one.
Configuration File Parameters
Parameter Affects Default Description
AdjOrient outbound 0 Automatically adjusts the image orientation if set to "1".
DefDetail outbound x The default detail message to send with each file found in this directory.
DefImgSize outbound 640x480 Set image dimensions to use for outbound images. (WxH)
DefOCE outbound undef The OCE to send files. The message containing the identified file will be sent to the specified OCE. There can be one, and only one OCE value in this field. If left blank or omitted the OSA/OCE standard default of the local OCE will be used.
DefRecip outbound undef Identifies the tribe member to receive the defined file message. The message will be sent to a local tribe member when "DefOCE" is blank, or to the member of the OCE specified in "DefOCE" if it is defined. The "DefOCE" value can be a comma separated list of more than one member. Member names can be "at" (@) sign delimited to include the destination OCE for each tribe member. Member names not including a delimited OCE reference will use the OSA/OCE default value of the local OCE.
DelSucc outbound 1 When set to "1", the sent file will be deleted from the directory it was found upon acceptance by the local OCE for sending.
DefSumm outbound x The default summary message to send with each file found in this directory.
Visibility outbound 2 The visibility value to use with messages generated from this directory.
OCEDir inbound 1 Create a subdirectory for each inbound OCE and store files from that OCE there. This feature is in the design phase and not yet implemented.


Image Resizing

The template to follow for specifying image sizes is as follows:
('x' is literally an "ex" character. '#' represents a number - any number)

  • ### Maximum size, defines a value to apply as maximum for either height or width
  • ###x Maximum width, proportional resizing to specified width.
  • x### Maximum height, proportional resizing to specified height
  • ###x### definitive height/width




Seven steps to using the Internet in privacy as a respected Netizen.
  1. Perspective
  2. Search
  3. Email
  4. Social Security
  5. Have Presence
  6. Take Control
  7. Break The Ties

Shoutbox

Steve: Fautore 0.6.0.0 is now released and available to our registered Alpha participants!
Steve: Fautore 5.3.0 is now released and includes dynamically updated stats reporting!
Steve: Fautore 0.5.2.3 FILES.pm patch is up on the site. Thanks for the inputs. Keep it coming. We'll make Fautore a reality together.