Skip to content

Commands ​

Introduction ​

You can run arbitrary Bash commands from the site's Commands page. Commands are executed from the site's root directory, for example /home/flashpanel/site.com. If you need to run a command in another directory, prefix it with a cd:

cd bin && ./run-command.sh

Run a command ​

Steps to execute a command:

  1. On the site management page, open Commands in the left-hand menu
  2. Enter the command in the Execute command editor. You can also click the Custom Scripts icon in the top-right corner of the editor to paste or immediately run a saved script (see Custom Scripts)
  3. Click the Execute command button (or press Ctrl/⌘ + S)

! No interactive input

Commands are not executed in an interactive terminal (tty), so you cannot provide input or passwords while a command is running.

Output limit

Only the first 50 KB of a command's output is kept. Use quiet flags or > /dev/null to print only what you need, see Output limit.

Command history ​

FlashPanel shows the command history in the Command history table below the editor, 5 most recent commands per page by default. Each row shows the first line of the command, who ran it, its status and the date.

Click a row to expand it and see the full command and its output, each with a copy icon. For security, the output is deleted 7 days after the command runs; the command itself is kept for 3 months.

The icons at the end of each row let you:

  • Copy the command
  • Edit this command before executing: load the command into the Execute command editor above, change it, then run it
  • Run the command again: execute the command again immediately