Our configuration File
The configuration file is a simple text file that defines how your application should be deployed on Shard Cloud. It includes details like the app’s main file, memory usage, programming language, and more. The file must be located in the rootCreating the configuration file
Just create a file named.shardcloud
and include the parameters described below.
Configuration parameters
These are the supported configuration parameters:DISPLAY_NAME [*]
Name that will appear for your application.
Max 50 characters.
DESCRIPTION
A brief description of your application.
Max 1024 characters.
MAIN [*]
Entry file of your application (only required if Max 50 characters. This field is ignored if
LANGUAGE
or CUSTOM_COMMAND
are not defined).CUSTOM_COMMAND
is present.LANGUAGE
Programming language of your application.
This parameter is automatically detected when
This parameter is automatically detected when
MAIN
is provided. If MAIN
is not set, you must explicitly define this parameter along with CUSTOM_COMMAND
.Accepted values:
node
, python
, java
, go
, static
, php
MEMORY [*]
RAM allocated to your application in MB.
Must be a positive integer.
VERSION [*]
Version to run your application with.
Accepted values:
recommended
, latest
SUBDOMAIN
Subdomain for your web application.Only alphanumeric characters. Max 100 characters.Website will be available at
mycoolapp.shardweb.app
CUSTOM_COMMAND
Custom command to start your application (optional).
Max 250 characters.
If
LANGUAGE
is set and CUSTOM_COMMAND
is used, the MAIN
parameter will be ignored.Configuration logic note 🧠
If bothLANGUAGE
and CUSTOM_COMMAND
are provided, then the MAIN
parameter will be ignored, even if specified. This gives you flexibility to fully customize startup behavior for more complex projects.
Example configurations
Minimal config
Full config with description and language
Config with custom startup
Website config with subdomain
Parameter limits summary
Parameter | Max Length |
---|---|
DISPLAY_NAME | 50 characters |
DESCRIPTION | 1024 characters |
MAIN | 50 characters |
CUSTOM_COMMAND | 250 characters |
SUBDOMAIN | 100 characters |
LANGUAGE | 35 characters |
MEMORY | Must be a valid non-negative integer |
VERSION | 60 characters |