Create new sandbox with YAML
YAML parameters for Create new sandbox
Name | Type | Description |
---|---|---|
action Required | String | The ID of the action. |
type Required | String | The type of the action. Must be set to SANDBOX_CREATE_NEW . |
sandbox_name Required | String | Defines the name of the created sandbox. |
sandbox_distribution Required | String | Defines the OS distro of the sandbox. Can be one of ubuntu/focal or debian/buster . |
sandbox_playbooks | SandboxPlaybook[] | Defines the list of playbooks to install during the sandbox creation. |
tags | String[] | The list of tags applied to the sandbox. |
ram_limit Required | Int | Defines the amount of RAM available to the sandbox. Can be one of 2 or 4 . |
cpu_limit Required | Int | Defines the number of vCPUs of the sandbox. Can be one of 1 or 2 . |
disk_size_limit Required | Int | Defines the sandbox disk size. Expressed in GB. Can be one of 5 or 10 . |
mappings Required | Mapping[] | Defines the port-subdomain mappings that allow to access exposed resources on the sandbox. |
application_port | Int | Defines the port used in the mapping. |
subdomain | String | Defines the subdomain used in the mapping. |
basic_auth | Boolean | If set to true , it allows you to use basic authorization in mappings |
mappings_username | String | Defines the basic auth username required to access the exposed resources. |
mappings_password | String | Defines the basic auth password required to access the exposed resources. |
Playbook parameters for Create new sandbox
Name | Type | Description |
---|---|---|
type Required | String | The type of the installed playbook. Can be one of DOCKER , APACHE , NGINX , WORDPRESS , NODE , RUBY , MARIA , MYSQL , POSTGRES , MONGO , or REDIS |
db | String | The initial database name. Available when type  is set to MARIA , WORDPRESS , POSTGRES , or MYSQL . |
user | String | Defines the username used in the desired service. Available when type is set to MARIA , WORDPRESS , POSTGRES , or MYSQL . |
password | String | Defines the password used in the desired service. Available when type is set to MARIA , WORDPRESS , POSTGRES , or MYSQL |
install_php | String | Installs PHP if set to true . Available when type  is set to APACHE , or NGINX . |
php_version | String[] | The PHP version of the installed playbook. Available when type  is set to APACHE  or NGINX . |
php_modules | String[] | The PHP modules of the installed playbook. Available when type  is set to APACHE  or NGINX . |
modules | String | The Apache modules of the installed playbook. Available when type  is set to APACHE . |
version | String | The version of the installed playbook. Available when type  is set to NODE , RUBY , MONGO , or MYSQL . |
YAML example for Create new sandbox (with playbooks)
actions:
- action: "Create new sandbox"
type: "SANDBOX_CREATE_NEW"
sandbox_name: "new sandbox with playbooks"
sandbox_distribution: "ubuntu/focal"
sandbox_playbooks:
- type: "APACHE"
install_php: true
php_version: "8.0"
php_modules:
- "gd"
- "mysql"
- "opcache"
- "curl"
- "xml"
- "mbstring"
- "imagick"
- "zip"
modules:
- "expires"
- "headers"
- "rewrite"
- type: "DOCKER"
- type: "MONGO"
version: "5.0"
- type: "NODE"
version: "12"
- type: "POSTGRES"
db: "test"
user: "test"
password: "test"
- type: "REDIS"
- type: "RUBY"
version: "2.7"
- type: "MYSQL"
version: "8.0"
db: "wp"
user: "wp"
password: "wp"
- type: "WORDPRESS"
db: "wp"
user: "wp"
password: "wp"
phrase: "wp"
ram_limit: 2
cpu_limit: 1
disk_size_limit: 5
mappings:
- application_port: 80
subdomain: "subdomain"
basic_auth: true
mappings_username: "root"
mappings_password: "secure!HgGGWOOdDRGVCt9A2E8iLQ==.lMfNW8nAd+N40qq0vd6z2w=="
YAML parameters for Duplicate existing sandbox
Name | Type | Description |
---|---|---|
action Required | String | The ID of the action. |
type Required | String | The type of the action. Must be set to SANDBOX_CREATE_FROM_SANDBOX . |
sandbox_name Required | String | Defines the name of the created sandbox. |
sandbox_id Required | String | Defines the ID of the existing sandbox used to create new sandbox. |
tags | String[] | The list of tags applied to the sandbox. |
ram_limit Required | Int | Defines the amount of RAM available to the sandbox. Can be one of 2 or 4 . |
cpu_limit Required | Int | Defines the number of vCPUs of the sandbox. Can be one of 1 or 2 . |
disk_size_limit Required | Int | Defines the sandbox disk size. Expressed in GB. Can be one of 5 or 10 . |
mappings Required | Mapping[] | Defines the port-subdomain mappings that allow to access exposed resources on the sandbox. |
application_port | Int | Defines the port used in the mapping. |
subdomain | String | Defines the subdomain used in the mapping. |
basic_auth | Boolean | If set to true , it allows you to use basic authorization in mappings |
mappings_username | String | Defines the basic auth username required to access the exposed resources. |
mappings_password | String | Defines the basic auth password required to access the exposed resources. |
YAML example for Duplicate existing sandbox
actions:
- action: "Create new sandbox from existing"
type: "SANDBOX_CREATE_FROM_SANDBOX"
sandbox_name: "sandbox-buddy"
sandbox_id: "BJ7YnoUVtfGdo"
tags:
- "tag_1"
- "tag_2"
ram_limit: 2
cpu_limit: 1
disk_size_limit: 5
mappings:
- application_port: 80
subdomain: "buddy-subdomain"
username: "root"
password: "secure!SNCLQcJdggA0xk2lxAxhiw==.ud7C2Ucd/M6SB9rtTHYvVQ=="
YAML parameters for Create from snapshot
Name | Type | Description |
---|---|---|
action Required | String | The ID of the action. |
type Required | String | The type of the action. Must be set to SANDBOX_CREATE_FROM_SNAPSHOT . |
sandbox_name Required | String | Defines the name of the created sandbox. |
snapshot_id Required | String | Defines the ID of the snapshot used to create a sandbox. |
tags | String[] | The list of tags applied to the sandbox. |
ram_limit Required | Int | Defines the amount of RAM available to the sandbox. Can be one of 2 or 4 . |
cpu_limit Required | Int | Defines the number of vCPUs of the sandbox. Can be one of 1 or 2 . |
disk_size_limit Required | Int | Defines the sandbox disk size. Expressed in GB. Can be one of 5 or 10 . |
mappings Required | Mapping[] | Defines the port-subdomain mappings that allow to access exposed resources on the sandbox. |
application_port | Int | Defines the port used in the mapping. |
subdomain | String | Defines the subdomain used in the mapping. |
basic_auth | Boolean | If set to true , it allows you to use basic authorization in mappings |
mappings_username | String | Defines the basic auth username required to access the exposed resources. |
mappings_password | String | Defines the basic auth password required to access the exposed resources. |
YAML example for Create from snapshot
actions:
- action: "Create new sandbox from snapshot"
type: "SANDBOX_CREATE_FROM_SNAPSHOT"
sandbox_name: "sandbox-buddy"
snapshot_id: "sn-SsWzv1Y1xBrYX"
tags:
- "tag_1"
- "tag_2"
ram_limit: 2
cpu_limit: 1
disk_size_limit: 5
mappings:
- application_port: 80
subdomain: "buddy-subdomain"
username: "root"
password: "secure!SNCLQcJdggA0xk2lxAxhiw==.ud7C2Ucd/M6SB9rtTHYvVQ=="
Last modified on May 17, 2022