Introduction

The configuration file is a file that will be used to configure your application, it will be used to define the name, description, version, among other things.

Creating the configuration file

Note: .app or .config is the file extension, not the name.

It”s very simple to create the configuration file, just create a file with the name squarecloud.app or squarecloud.config and put the configuration parameters inside it.

Configuration parameters

Minimum memory for bot is 100mb (256MB MINIMUM RECOMMENDED) and for website 512mb
Required parametersDescriptionExample
MAINMain file of your applicationMAIN=index.js
MEMORYAmount of memory ramMEMORY=256
VERSIONVersion of your applicationVERSION=recommended
DISPLAY_NAMEName of applicationDISPLAY_NAME=My app!
SUBDOMAINIf you are sending a websiteSUBDOMAIN=mysite
Optional parametersDescription
DESCRIPTIONDescription of your application
AUTORESTARTRestart your application if it crashes
START*Custom startup command

Examples of configuration

This example just use required parameters. (minimum configuration)
MAIN=index.js
MEMORY=256
VERSION=recommended
DISPLAY_NAME=My app!
This example use all parameters.
MAIN=index.js
MEMORY=256
VERSION=recommended
DISPLAY_NAME=My app!
DESCRIPTION=My app is very cool!
Website url will be: mysite.squareweb.app
This example use all parameters and custom startup command in a website.
MAIN=index.js
MEMORY=512
VERSION=recommended
DISPLAY_NAME=My website!
DESCRIPTION=My website is very cool!
SUBDOMAIN=mysite
START=npm run start-build
AUTORESTART=true

Versions

For each language there is a different VERSION parameter, below you can see the available versions for each language. Updated on 07/29/2023.

LanguageVersion recommendedVersion latestOld version
JavaScript [Node.js]20.9.0 (LTS - 2023)21.1.0
Python3.11.63.12
JavaJDK 17JDK 18
Elixir1.15.41.15.4
Rust1.76.01.76.0
PHP8.2.108.2.10
Go1.21.31.21.3
HTML/CSSBuild 07-29-23Build 07-29-23

Technical limits

For security and performance reasons, there are limits on the configuration parameters, below you can see the limits of each parameter.

ParameterLimit
MAIN32 characters
DISPLAY_NAME32 characters
DESCRIPTION280 characters
START128 characters
SUBDOMAIN63 characters