Fix binary locations in documentation.

pull/7/head 1.2
Ferry Boender 8 years ago
parent 9c3fde01c6
commit cb3abe7213
  1. 17
      README.md
  2. 7
      doc/MANUAL.md

@ -179,37 +179,38 @@ point at the form configuration JSON file you'd like to use.
Usage: Usage:
Usage: ./scriptform.py [option] (--start|--stop) <form_definition.json> Usage: /usr/bin/scriptform [option] (--start|--stop) <form_definition.json>
./scriptform.py --generate-pw /usr/bin/scriptform --generate-pw
Options: Options:
--version show program's version number and exit
-h, --help show this help message and exit -h, --help show this help message and exit
-g, --generate-pw Generate password -g, --generate-pw Generate password
-p PORT, --port=PORT Port to listen on -p PORT, --port=PORT Port to listen on (default=80)
-f, --foreground Run in foreground (debugging) -f, --foreground Run in foreground (debugging)
-r, --reload Reload form config on every request (DEV)
--pid-file=PID_FILE Pid file --pid-file=PID_FILE Pid file
--log-file=LOG_FILE Log file --log-file=LOG_FILE Log file
--start Start daemon --start Start daemon
--stop Stop daemon --stop Stop daemon
ScriptForm can run both in daemon mode or in the foreground. In daemon mode, we ScriptForm can run both in daemon mode or in the foreground. In daemon mode, we
can control ScriptForm with the `--start` and `--stop` options. By default it can control ScriptForm with the `--start` and `--stop` options. By default it
runs on port 80, which we can change with the `-p` option. runs on port 80, which we can change with the `-p` option.
$ ./scriptform -p8081 ./test_server.json $ scriptform -p8081 ./test_server.json
This puts ScriptForm in the background as a daemon. It creates a PID file and a This puts ScriptForm in the background as a daemon. It creates a PID file and a
log file. log file.
$ tail scriptform.py.log $ tail scriptform.log
2015-04-08 07:57:27,160:DAEMON:INFO:Starting 2015-04-08 07:57:27,160:DAEMON:INFO:Starting
2015-04-08 07:57:27,161:DAEMON:INFO:PID = 5614 2015-04-08 07:57:27,161:DAEMON:INFO:PID = 5614
2015-04-08 07:57:27,162:SCRIPTFORM:INFO:Listening on 0.0.0.0:8081 2015-04-08 07:57:27,162:SCRIPTFORM:INFO:Listening on 0.0.0.0:8081
In order to stop the daemon: In order to stop the daemon:
$ ./scriptform --stop $ scriptform --stop
We can control the location of the PID file and log file with the `--pid-file` We can control the location of the PID file and log file with the `--pid-file`
and `--log-file` options. If we don't specify these, ScriptForm will create and `--log-file` options. If we don't specify these, ScriptForm will create
@ -220,7 +221,7 @@ To run ScriptForm in the foreground, specify the `-f` option.
If you're going to use basic authentication, you can generate a password for If you're going to use basic authentication, you can generate a password for
your user with the `--generate-pw` option: your user with the `--generate-pw` option:
$ ./scriptform.py --generate-pw $ scriptform --generate-pw
Password: Password:
Repeat password: Repeat password:
2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae 2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae

@ -1194,11 +1194,16 @@ Passwords are unsalted SHA256 hashed passwords. To generate one, you can use
the `--generate-pw` option of Scriptform. This will ask you twice for a the `--generate-pw` option of Scriptform. This will ask you twice for a
plaintext password and return the hash that can be used in the `users` element. plaintext password and return the hash that can be used in the `users` element.
$ ./scriptform.py --generate-pw $ scriptform --generate-pw
Password: Password:
Repeat password: Repeat password:
ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad
**Note** that if you're running from the repository, you'll have to run
Scriptform as:
$ src/scriptform.py --generate-pw
### <a name="users_formlimit">Form limiting</a> ### <a name="users_formlimit">Form limiting</a>
You may specify a `allowed_users` field in a form definition. Only user names You may specify a `allowed_users` field in a form definition. Only user names

Loading…
Cancel
Save