httpreq.toml raw

   1  Name = "HTTP request"
   2  Description = ''''''
   3  URL = "/lego/dns/httpreq/"
   4  Code = "httpreq"
   5  Since = "v2.0.0"
   6  
   7  Example = '''
   8  HTTPREQ_ENDPOINT=http://my.server.com:9090 \
   9  lego --dns httpreq -d '*.example.com' -d example.com run
  10  '''
  11  
  12  Additional = '''
  13  ## Description
  14  
  15  The server must provide:
  16  
  17  - `POST` `/present`
  18  - `POST` `/cleanup`
  19  
  20  The URL of the server must be defined by `HTTPREQ_ENDPOINT`.
  21  
  22  ### Mode
  23  
  24  There are 2 modes (`HTTPREQ_MODE`):
  25  
  26  - default mode:
  27  ```json
  28  {
  29    "fqdn": "_acme-challenge.domain.",
  30    "value": "LHDhK3oGRvkiefQnx7OOczTY5Tic_xZ6HcMOc_gmtoM"
  31  }
  32  ```
  33  
  34  - `RAW`
  35  ```json
  36  {
  37    "domain": "domain",
  38    "token": "token",
  39    "keyAuth": "key"
  40  }
  41  ```
  42  
  43  ### Authentication
  44  
  45  Basic authentication (optional) can be set with some environment variables:
  46  
  47  - `HTTPREQ_USERNAME` and `HTTPREQ_PASSWORD`
  48  - both values must be set, otherwise basic authentication is not defined.
  49  
  50  '''
  51  
  52  [Configuration]
  53    [Configuration.Credentials]
  54      HTTPREQ_MODE = "`RAW`, none"
  55      HTTPREQ_ENDPOINT = "The URL of the server"
  56    [Configuration.Additional]
  57      HTTPREQ_USERNAME = "Basic authentication username"
  58      HTTPREQ_PASSWORD = "Basic authentication password"
  59      HTTPREQ_POLLING_INTERVAL = "Time between DNS propagation check in seconds (Default: 2)"
  60      HTTPREQ_PROPAGATION_TIMEOUT = "Maximum waiting time for DNS propagation in seconds (Default: 60)"
  61      HTTPREQ_HTTP_TIMEOUT = "API request timeout in seconds (Default: 30)"
  62