File tree Expand file tree Collapse file tree 1 file changed +19
-6
lines changed Expand file tree Collapse file tree 1 file changed +19
-6
lines changed Original file line number Diff line number Diff line change 1
1
```
2
2
zulip-botserver --config-file <path to botserverrc> --hostname <address> --port <port>
3
-
4
3
```
5
4
6
5
Example: ` zulip-botserver --config-file ~/botserverrc `
7
6
8
7
This program loads the bot configurations from the
9
- config file (botserverrc here) and loads the bot modules.
8
+ config file (` botserverrc ` , here) and loads the bot modules.
10
9
It then starts the server and fetches the requests to the
11
10
above loaded modules and returns the success/failure result.
12
11
13
- Please make sure you have a current botserverrc file with the
14
- configurations of the required bots.
15
- Hostname and Port are optional arguments. Default hostname is
16
- 127.0.0.1 and default port is 5002.
12
+ The ` --hostname ` and ` --port ` arguments are optional, and default to
13
+ 127.0.0.1 and 5002 respectively.
14
+
15
+ The format for a configuration file is:
16
+
17
+ [helloworld]
18
+ key=value
19
+
20
+ site=http://localhost
21
+ token=abcd1234
22
+
23
+ Is passed ` --use-env-vars ` instead of ` --config-file ` , the
24
+ configuration can instead be provided via the ` ZULIP_BOTSERVER_CONFIG `
25
+ environment variable. This should be a JSON-formatted dictionary of
26
+ bot names to dictionary of their configuration; for example:
27
+
28
+ ZULIP_BOTSERVER_CONFIG='{"helloworld":{"email":"[email protected] ","key":"value","site":"http://localhost","token":"abcd1234"}}' \
29
+ zulip-botserver --use-env-vars
You can’t perform that action at this time.
0 commit comments