Skip to main content
Virtus Cloud supports Java applications through standard JAR-based deployments. You compile your project locally, package it as an executable JAR, and upload it together with your MANIFEST.MF and Virtus Cloud configuration file. The platform launches your application using java -jar, giving you a clean, managed JVM runtime without any server configuration. This guide covers the full process from setup to deployment.

Prerequisites

Before you deploy, make sure you have the following:

JDK versions

Virtus Cloud provides two JDK versions you can select in your config file:
VERSION valueJDK version
recommendedJDK 23
latestJDK 25
Use VERSION=recommended for production deployments. JDK 23 is the platform’s well-tested default and is suitable for the vast majority of Java applications.

Create your config file

Every Virtus Cloud deployment requires a virtuscloud.app configuration file at the root of your project. Set MAIN to the name of your compiled JAR file.

Config File Reference

Learn every available parameter — MAIN, MEMORY, VERSION, DISPLAY_NAME, SUBDOMAIN, START, and more.
virtuscloud.app
MAIN=project.jar
MEMORY=512
VERSION=recommended
DISPLAY_NAME=My Java App

Startup behavior

Virtus Cloud determines how to start your application based on whether the START field is set in your config file.
  • If START is not set, the platform runs java -jar MAIN, where MAIN is the JAR file defined in your config.
  • If START is set, the platform executes the START command directly, giving you full control over JVM flags and arguments.
Custom start with JVM flags
START=java -Xmx512m -jar project.jar
For more information on all startup parameters, see the Config File Reference.

Required files

Your ZIP archive must include the following files:
FilePurpose
virtuscloud.app or virtuscloud.configPlatform configuration
project.jar (or your compiled JAR file)Compiled application bundle
MANIFEST.MFJAR manifest with entry point metadata
The virtuscloud.app config file must be at the root of the ZIP archive. If it is inside a subfolder, Virtus Cloud cannot find it during deployment.
Compile your Java project and package it as a self-contained JAR (fat JAR / uber JAR) before uploading. Include all runtime dependencies inside the JAR so the platform does not need an external classpath.

Preparing your project for upload

Before creating your ZIP archive, build your project with Maven, Gradle, or your preferred build tool:
mvn clean package
Your compiled JAR will be in target/ (Maven) or build/libs/ (Gradle). Copy it to your project root alongside MANIFEST.MF and virtuscloud.app.

Upload your project

Once your files are ready, package them into a .zip archive and upload using your preferred method.
1

Install the CLI

If you do not have the Virtus Cloud CLI installed, run the appropriate command for your system:
curl -fsSL https://cli.virtuscloud.app/install | bash
To update an existing installation:
virtuscloud update
2

Authenticate

Retrieve your API key from virtuscloud.app/account by clicking Request API Key, then run:
virtuscloud login
3

Deploy

From your project directory, run:
virtuscloud upload
Or pass the path to an existing ZIP file:
virtuscloud upload my-project.zip

Troubleshooting

This error appears when the JAR file specified in MAIN does not exist in your ZIP archive. Make sure the JAR filename in your config matches the actual filename exactly, including the .jar extension.
The minimum RAM for a bot is 256 MB and for a website or API is 512 MB. JVM-based applications often require more memory than lighter runtimes. Increase the MEMORY value in your config if you see out-of-memory errors. See the LACK_OF_RAM troubleshooting guide for more details.
This error means a dependency class was not found in the JAR. Make sure you are building a fat JAR (uber JAR) that includes all runtime dependencies. With Maven, use the maven-shade-plugin or maven-assembly-plugin. With Gradle, use the shadow plugin.
If you continue to experience issues after reviewing this guide, contact the Virtus Cloud support team.