Deploy Backend Apps


To deploy a backend application on Hostman, go to the App Platform section and click Create app.

Step 1. Connect Your Repository
Copy link

You can connect a repository in one of two ways:

From your GitHub, GitLab, or BitBucket account

  1. Click on the platform name.
  2. Log in to your account.
  3. Select the desired repository in your Hostman dashboard.

If you are already logged in, Hostman will immediately show the available repositories. Choose the one you need.

By URL

You can connect any repository from any platform by providing its Git URL.

  1. Click Connect the repository via URL.
  2. Enter the Git URL of the repository. 
  3. If the repository is private, also enter the access details.

Read more about connecting repositories here.

App Platform automatically detects your application's framework and runtime version from the repository, but you can change them manually if needed.

Step 2. Select Branch and Commit
Copy link

Branch

Select a branch for deployment. 

The menu displays the 200 most recent branches, as well as the default branch (master, main, or default) if the repository is connected via GitHub, GitLab, or Bitbucket.

Commit

Leave the Build by the last executed commit option enabled if you want App Platform to deploy the latest commit and automatically rebuild the application when you add new commits to the repository. You can disable automatic deployment in the future.

If you want to select a specific commit, disable this option. Note that it will also disable automatic deployments.

Step 3. Select Server Region and Configuration
Copy link

Region

Your application must run on a separate cloud server. Select the region where the server should be located.

Configuration

Select the server configuration. You can always upgrade your server later, however, downgrading will not be possible.

Step 4. Configure Additional Settings
Copy link

Click Show advanced settings to configure additional parameters. 

Private Network

You can add the application to a private network and specify the IP address the app will use.

Apps with a private IP address may experience a short downtime during redeployment, as existing ports need to be freed up before the new version starts.

Build Command

The command used to build the application from the repository root. Adjust it if necessary.

Dependencies

If you need additional system packages (for example, for building a project), specify them here. They will be passed to the apt install command. 

You can enter multiple dependencies separating them with spaces.

Start Command

In most cases, App Platform will automatically determine the start command for your project, so you can leave it unchanged.

Project Directory Path

If your project files are located in a subdirectory rather than in the repository root, specify the path to that directory in this field.

When a project directory path is specified:

  • The working directory switches to the specified folder.
  • Dependencies are installed using the project files located in that folder.
  • Build and run commands are also executed from that folder.

Health Check Path

App Platform uses the health check path to periodically verify that your application is running and functioning correctly. See more here.

Environment Variables

Use variables to store and pass configuration values such as passwords, file paths, and tokens. See more here.

Step 5. Enter the App Information
Copy link

Here you can specify a name and a comment for your application to be displayed in the Hostman dashboard. You can also select a project to add the app to.

These settings can also be changed later.

Step 6. Deploy
Copy link

Click Create. Once the process starts, you will see the deployment log on the Deploy tab.

The deploy log contains all the necessary information to solve possible issues. If something goes wrong, for example, due to errors in the code, the deploy log will display the notification about it specifying the cause of the problem.

When you first deploy a project, the server installation may take some time. Once the process is completed, the application status will be updated, and you will also see a message about this in the log.

All done!

You can find the application's IP address and the technical domain linked to the app in the Dashboard tab. The application will be available on port 443; port 80 is also open.

To link your own domain to the app, follow this guide.

In the future, App Platform will monitor updates in the repository and, if automatic deployment is enabled, automatically rebuild the project with new changes.