Skip to content

Applications ​

Applications runs a Node.js, Python, or Ruby application on one of your domains. The wizard ships a starter page that serves immediately, so you can confirm the application is running before you put your own code there.

Overview ​

URL: /client/applications

The page sits under Domains in the client navigation. It is there only when your hosting plan includes applications and the server can run them. If it is missing, ask your hosting provider.

The applications list

Each application belongs to one domain. A domain that already runs an application is not offered again.

Creating an application ​

New Application opens a four-step wizard.

1. Runtime ​

FieldWhat to choose
DomainThe domain the application will serve. Only domains not already running one are listed.
Application NameA name for the application.
RuntimeNode.js, Python, or Ruby.
Runtime VersionA version your server has installed, or the server default.

The runtime list says what each option can actually do on this server. A runtime marked cannot be served on this server is one the web server does not support; a runtime marked needs setup by your administrator is one the server can serve once your administrator finishes setting it up; a runtime marked not installed on this server has no version installed yet. The version field names the versions this server has.

If every runtime is marked that way, ask your hosting provider before going further. Applications run on Apache with Phusion Passenger, on OpenLiteSpeed, and on LiteSpeed Enterprise in native mode. On a server that cannot run any application, for example Apache without Passenger, or LiteSpeed Enterprise in its older Apache drop-in mode, Applications is not shown at all, so you cannot build something that would not start.

2. Location ​

Where the code lives and how it starts. The application root is taken relative to your domain's folder, so you give a path inside your own space rather than a full server path.

3. Environment ​

The variables passed to the application. This is where configuration such as connection strings and API keys belongs, rather than in the code.

4. Starter application ​

A minimal application that serves a page as soon as it is created. Keep it for the first run: if the starter page loads, the domain, runtime, and startup are all correct, and anything that breaks afterwards is your own code.

Running an application ​

Each application in the list has these actions:

ActionWhat it does
EditChange the application's settings.
RestartRestart the running application. Restart after changing code or environment variables; the running process does not pick either up on its own.
Stop / StartStop the application, or start it again. While it is stopped, visitors see an error page.
Install DependenciesInstall the packages your application needs. See Installing dependencies.
LogsThe application's own log.
RemoveThe domain goes back to being served by PHP. Your files are left untouched.

Restart, Install Dependencies, and Remove are also at the top of the application's edit page.

Installing dependencies ​

Install Dependencies runs the runtime's package manager as your account, in the application folder. The confirmation names the command:

RuntimeCommand
Node.jsnpm install --omit=dev
Pythonpython3 -m pip install --user -r requirements.txt
Rubybundle config set --local path 'vendor/bundle' && bundle install

Since panel 1.9.2, for Node.js the panel runs the npm that belongs to the Node.js version selected for the application, the same version the application runs on, rather than whichever npm the server finds first. Change the version, and the next install uses the new one's npm. If that Node.js version, or its npm, is not installed on the server, nothing runs and the message asks you to contact your hosting provider.

The result comes back as a notification:

  • Dependencies installed. when the command succeeded, with what it printed.
  • Dependencies were not installed. when it failed. Since panel 1.9.2 the notification shows what the command printed, so you can see why, for example a package that could not be found. When the output is long, the end is kept and marked (output shortened).
  • An install that runs longer than 10 minutes is stopped, and the message says so. Try again, or install the dependencies over SSH.

Over the API ​

Applications are fully covered by the client REST API: listing, creating, updating, deleting, reading the log, restarting, and installing dependencies. That is what makes a deployment script possible without a panel session.

  • POST /api/client/applications/{domain_id}/dependencies installs the dependencies the same way Install Dependencies does, and returns what the package manager printed. A failed install answers 422 with a message and the output.
  • Since panel 1.9.2, creating an application on a server that cannot run applications yet answers 422 and creates nothing. The message says what is missing and who can fix it, and problem names it: not_installed or not_enabled for Phusion Passenger on Apache, or litespeed_drop_in for LiteSpeed Enterprise in Apache drop-in mode. Applications that already exist stay manageable.
  • Domains - the domains an application can be attached to.
  • File Manager - where the application's code lives.
  • Error Logs - the domain's web server errors, separate from the application's own log.
  • Databases - the databases an application connects to.