Skip to main content

πŸš€ Introduction

  • Ensure Node.js and npm are installed on your system. If not, download them from the official Node.js website.
  • Create an account on DS Cloud via the login page using your email, Discord, or both.
  • Make sure you have an active paid plan. View and purchase plans here.

βš™οΈ Creating the dscloud config file

Learn about: how to make the configuration file for DS Cloud.

The dscloud.pt file configures your application, defining its name, description, version, main file, and more.

▢️ Start Application

  • If the START field is not defined in the configuration file, DS Cloud runs node with optimization options and specific parameters. If the START field is defined, its value will be executed directly. Learn more about configuration file parameters here.
  • If node_modules does not exist, DS Cloud runs npm install --no-package-lock --no-audit --no-fund to install dependencies and clean the .npm folder.

πŸ–₯️ Preparing Your Node.js Project

πŸ“ Essential Configuration Files

To deploy your Node.js project on DS Cloud, include your configuration file (dscloud.pt/.config) and essential application files in a zip file.
The configuration file (dscloud.pt/.config) must be in the root of the zip file; otherwise, DS Cloud won’t find it during deployment.

πŸ—‘οΈ Files to Exclude Before Uploading

  • node_modules: DS Cloud will create this folder during installation in the production environment.
  • package-lock.json: Dependencies will be installed based on package.json in the production environment.

πŸ€” Why Exclude These Files?

  1. Installation Consistency: Excluding node_modules ensures dependencies are installed by the production environment, preventing local discrepancies.
  2. Updated Installations: Dependencies are installed with the latest compatible versions listed in package.json.
  3. Reduced Upload Size: Smaller upload files improve efficiency and deployment speed.

πŸ“„ Required Files

Three files are essential for hosting your Node project:
DS Cloud supports TypeScript natively, running projects through ts-node, but compiling to JavaScript is recommended for production.

πŸ’‘ Troubleshooting

Ensure the β€œmain” file specified in the configuration exists, is correctly named, and has the correct path. For files in subfolders, use folder/file.js.
Minimum RAM requirements:
  • Bots: 256MB
  • Websites/APIs: 512MB Depending on application size and complexity, allocate more RAM to avoid the LACK_OF_RAM error.

πŸ“€ Uploading Project to DS Cloud

After preparing your project files, upload them to DS Cloud to host your application.
  • Go to the DS Cloud Discord server and use the /up command in the #commands channel.
  • A new private channel will be created for you.
  • Upload your .zip file in the created channel to deploy your application.
If you encounter any issues, contact our support team.