You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/Configuration/Core-Configuration/Asterisk-Builtin-mini-HTTP-Server.md
+27-13Lines changed: 27 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,30 +3,44 @@ title: Asterisk Builtin mini-HTTP Server
3
3
pageid: 28315001
4
4
---
5
5
6
-
Overview
7
-
========
6
+
## Overview
8
7
9
-
The core of Asterisk provides a basic HTTP/HTTPS server.
8
+
Asterisk provides a basic built-in HTTP/HTTPS server.
10
9
11
-
Certain Asterisk modules may make use of the HTTP service, such as the [Asterisk Manager Interface](/Configuration/Interfaces/Asterisk-Manager-Interface-AMI) over HTTP, the [Asterisk Restful Interface](/Configuration/Interfaces/Asterisk-REST-Interface-ARI/Getting-Started-with-ARI) or WebSocket transports for modules that support that, like chan_sip or chan_pjsip.
10
+
Certain Asterisk modules may make use of the HTTP service, such as the [Asterisk Manager Interface](/Configuration/Interfaces/Asterisk-Manager-Interface-AMI) over HTTP, the [Asterisk Restful Interface](/Configuration/Interfaces/Asterisk-REST-Interface-ARI/Getting-Started-with-ARI) or WebSocket transports for modules that support that, like chan_pjsip.
12
11
13
-
Configuration
14
-
=============
12
+
## Configuration
15
13
16
-
The configuration sample file is [by default](/Fundamentals/Directory-and-File-Structure) located at /etc/asterisk/http.conf
14
+
The configuration file is [by default](/Fundamentals/Directory-and-File-Structure) located at `/etc/asterisk/http.conf`.
17
15
18
-
A very basic configuration of http.conf could be as follows:
16
+
A very basic configuration of `http.conf` could be as follows:
19
17
20
18
```
21
19
[general]
22
20
enabled=yes
23
21
bindaddr=0.0.0.0
24
-
bindport=8088
25
22
```
26
23
27
-
That configuration would enable the HTTP server and have it bind to all available network interfaces on port 8088.
24
+
That configuration would enable the HTTP server and have it bind to all available network interfaces on the default port 8088.
28
25
29
-
Configuration Options
30
-
=====================
26
+
### Configuration Options
31
27
32
-
See the sample file in your version of Asterisk for detail on the various configuration options, as this information is not yet automatically pushed to the wiki.
28
+
Some important configuration options are shown below.
29
+
30
+
| Value | Description |
31
+
| ----- | ----------- |
32
+
|**servername**| Name of the webserver. Defaults to "Asterisk/{version}" |
33
+
|**enabled**| Must be set to "yes" for the server to run |
34
+
|**bindaddr**| Address to bind to for HTTP sessions. Must be set for the server to run |
35
+
|**bindport**| Port to bind to for HTTP sessions. Default is 8088 |
36
+
|**enable_static**| If static content from `static-http` should be served. Defaults to "no" |
37
+
38
+
Static content serving can be useful if you are using IP Phones which fetch configuration over HTTP. With **enable_static** set to "yes", files in `/var/lib/asterisk/static-http/` will be made available at `http://192.0.2.5/static/` (replace the example IP Address with your Asterisk server or domain name).
39
+
40
+
The built-in server also supports HTTPS, with options available for supplying certificate paths, etc.
41
+
42
+
See the [sample configuration file supplied with Asterisk sources](https://github.com/asterisk/asterisk/blob/master/configs/samples/http.conf.sample) for full detail on all possible configuration options.
43
+
44
+
## Console Command
45
+
46
+
The built-in server supports a single Asterisk console command `http show status`. This outputs the status of the built-in server, including details on if the server is enabled, which IP and port it is bound to, enabled URIs, and enabled Redirects.
0 commit comments