# MKTAP.1

## NAME

mktap - create twisted.servers

## SYNOPSIS

mktap [options] apptype [application_option]...

mktap --help apptype

## DESCRIPTION

The --help prints out a usage message to standard output.

--uid, -u<uid>
  Application belongs to this uid, and should run with its permissions.
--gid, -d<gid>
  Application belongs to this gid, and should run with its permissions.
--append, -a<file>
  Append given servers to given file, instead of creating a new one. File should be be a tap file.
--appname, -n<name>
  Use the specified name as the process name when the application is run with twistd(1). This option also causes some initialization code to be duplicated when twistd(1) is run.
--xml, -x
  Output as a .tax XML file rather than a pickle.
--source, -s
  Output as a .tas (AOT Python source) file rather than a pickle.
apptype
  Can be 'web', 'portforward', 'toc', 'coil', 'words', 'manhole', 'im', 'news', 'socks', 'telnet', 'parent', 'sibling', 'ftp', and 'mail'. Each of those support different options.

## portforward options

-h, --host<host>
  Proxy connections to <host>
-d, --dest_port<port>
  Proxy connections to <port> on remote host.
-p, --port<port>
  Listen locally on <port>

## web options

-u, --user
  Makes a server with ~/public_html and ~/.twistd-web-pb support for users.
--personal
  Instead of generating a webserver, generate a ResourcePublisher which listens on ~/.twistd-web-pb
--path<path>
  <path> is either a specific file or a directory to be set as the root of the web server. Use this if you have a directory full of HTML, cgi, php3, epy, or rpy files or any other files that you want to be served up raw.
-p, --port<port>
  <port> is a number representing which port you want to start the server on.
-m, --mime_type<mimetype>
  <mimetype> is the default MIME type to use for files in a --path web server when none can be determined for a particular extension. The default is 'text/html'.
--allow_ignore_ext
  Specify wether or not a request for 'foo' should return 'foo.ext'. Default is off.
-t, --telnet<port>
  Run a telnet server on <port>, for additional configuration later.
-i, --index<name>
  Use an index name other than index.html
--https<port>
  Port to listen on for Secure HTTP.
-c, --certificate<filename>
  SSL certificate to use for HTTPS. [default: server.pem]
-k, --privkey<filename>
  SSL certificate to use for HTTPS. [default: server.pem]
--processor<ext>=<class name>
  Adds a processor to those file names. (Only usable if after --path)
--resource-script<script name>
  Sets the root as a resource script. This script will be re-evaluated on every request.

This creates a web.tap file that can be used by twistd. If you specify no arguments, it will be a demo webserver that has the Test class from twisted.web.test in it.

## toc options

-p<port>
  <port> is a number representing which port you want to start the server on.

## mail options

-r, --relay<ip>,<port>=<queue directory>
  Relay mail to all unknown domains through given IP and port, using queue directory as temporary place to place files.
-d, --domain<domain>=<path>
  generate an SMTP/POP3 virtual maildir domain named domain which saves to path
-u, --username<name>=<password>
  add a user/password to the last specified domains
-b, --bounce_to_postmaster
  undelivered mails are sent to the postmaster, instead of being rejected.
-p, --pop<port>
  <port> is a number representing which port you want to start the pop3 server on.
-s, --smtp<port>
  <port> is a number representing which port you want to start the smtp server on.

This creates a mail.tap file that can be used by twistd(1)

## telnet options

-p, --port<port>
  Run the telnet server on <port>
-u, --username<name>
  set the username to <name>
-w, --password<password>
  set the password to <password>

## socks options

-i, --interface<interface>
  Listen on interface <interface>
-p, --port<port>
  Run the SOCKSv4 server on <port>
-l, --log<filename>
  log connection data to <filename>

## ftp options

-a, --anonymous
  Allow anonymous logins
-3, --thirdparty
  Allow third party connections
--otp
  Use one time passwords (OTP)
-p, --port<port>
  Run the FTP server on <port>
-r, --root<path>
  Define the local root of the FTP server
--anonymoususer<username>
  Define the the name of the anonymous user

## manhole options

-p, --port<port>
  Run the manhole server on <port>
-u, --user<name>
  set the username to <name>
-w, --password<password>
  set the password to <password>

## words options

-p, --port<port>
  Run the Words server on <port>
-i, --irc<port>
  Run IRC server on port <port>
-w, --web<port>
  Run web server on port <port>

## AUTHOR

Written by Moshe Zadka, based on mktap's help messages

## REPORTING BUGS

Report bugs to <twisted-python@twistedmatrix.com>.

## COPYRIGHT

Copyright © 2000 Matthew W. Lefkowitz This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

## SEE ALSO

twistd(1)

Index