DIST(8)

NAME
connect, dispatch - generic network client and server

query, receive, notify - network clients

answer, transmit, notified - network servers

SYNOPSIS
/usr/lib/dist/connect remote-system remote-cmd io local-cmd local-args

/usr/lib/dist/query

/usr/lib/dist/receive package-id

/usr/lib/dist/notify package-id

/usr/lib/dist/dispatch remote-system remote-user

/usr/lib/dist/answer remote-system remote-user

/usr/lib/dist/transmit remote-system remote-user

/usr/lib/dist/notified remote-system remote-user

DESCRIPTION
These programs act behind the scenes on behalf of dist(1). Connect and dispatch deal with all the details of establishing and authenticating connections on the network. The remaining programs are independent of the underlying network.

Connect encapsulates all the details of making a call on the underlying network. Its arguments are mostly self explanatory. Remote-cmd must be one of answer, transmit, or notified. If io is i, the standard input of the local command is connected to the standard output of the remote command. If i is not specified, the local command inherits its local standard input, and the remote command has its standard output directed to a log file. Similarly, o means the standard output of the local command is connected to the standard input of the remote command. If o is not specified, the local command inherits its local standard output, and the remote command has its standard input attached to /dev/null. Legal possibilities are i, o, and io.

Dispatch is intended to be called by a generic network daemon such as svcmgr(8). It talks to connect and takes care of establishing the appropriate standard input and output before calling answer, transmit, or notified. Dispatch expects arguments giving the remote system, remote user, and remote address, and passes these to whatever program it calls.

Query is a simple program called by connect with its standard input attached to the remote answer. Query displays a formatted version of the queue list from the remote machine. (It may even turn out to be the same as /bin/cat.)

Receive is a more complicated program that is called by connect with both its input and output attached to the remote transmit. Receive performs actual software installation and sends a transcript of any errors back to the remote system.

Notify is a simple program called by connect with its standard output attached to the remote notified. Notify sends an announcement of the availability of some specific package.

All of the servers read a configuration file, /usr/lib/dist/conf, to determine how to handle installation on behalf of a given remote system and user. The file consists of lines containing patterns and actions. Empty lines or lines beginning with a '#' are ignored. The first three fields (separated by white space) of each line are regular expressions to be matched the remote system name, remote user name, and file name respectively. The first line in which all three match will be chosen. The remainder of the line contains the associated actions. Each action is an alphanumeric name, optionally followed immediately by a parenthesized argument.

Someday the actions will be enumerated here, but I don't know what they are yet.

EXAMPLES
A simple configuration file:
    # system	user		pathname	action
    # we are willing to distribute stuff to coma and pyxis.
    (coma|pyxis)	.*		.*		accept(yes)
    .*		.*		.*		accept(no)

SEE ALSO
dist(1), dist(5)