Reference

prompt

Initiate an interactive session with the Runtime API.

Description Jump to heading

Using prompt, you can begin an interactive session wherein you can enter commands without needing to reconnect to the API each time.

Examples Jump to heading

  1. Connect to the Runtime API socket:

    bash
    sudo socat stdio tcp4-connect:127.0.0.1:9999
    bash
    sudo socat stdio tcp4-connect:127.0.0.1:9999
  2. Start an interactive session:

    bash
    prompt
    bash
    prompt

Then you can send other Runtime API commands.

Available since

  • HAProxy 2.8
  • HAProxy Enterprise 2.8r1

As of version 2.8r1, you can provide an additional argument timed to the prompt command which will show the process’ uptime on the prompt.

bash
sudo socat stdio tcp4-connect:127.0.0.1:9999
bash
sudo socat stdio tcp4-connect:127.0.0.1:9999
bash
prompt timed
bash
prompt timed

The prompt will then show with the process’ uptime.

output
bash
[0:00:15:55]>
output
bash
[0:00:15:55]>

See also Jump to heading

If this page was useful, please, Leave the feedback.

© 2023 HAProxy Technologies, LLC. All Rights Reserved
Manage Cookie Preferences