The Environment Resource

Environments are groups of containers with a private network built between them. For more information on environments, see the main docs.

Environment Attributes
  • id
    string

    A unique identifier for the environment.

  • name
    string

    A user defined name for the environment resource.

  • cluster
    string

    The cluster this environment is associated with.

  • about
    object

    Contains details regarding the environment.

    Show child fields
  • creator
    object
    includable

    A creator object. Describes who created the resource.

    Show child fields
  • hub_id
    string

    The unique ID of the Hub this environment resource was created in.

  • state
    object

    Information regarding the current state of the environment.

    Show child fields
  • events
    object

    A collection of timestamps for each event in the environment's lifetime.

    Show child fields
  • features
    object

    An object representing specialized features configured for this environment.

    Show child fields
  • services
    object

    Service containers run by this environment and their configurations.

    Show child fields
  • private_network
    object | null

    Information about the private network associated with the environment. Will be null if the environment has never had a running container.

    Show child fields
  • meta
    object
    optional

    A list of meta fields that can be applied to this environment. See the meta section for more details.

    Show child fields
Example Environment
{
"data": [
{
"data": {
"id": "5b9c2a77b6393d0001eb45fd",
"name": "Demo Name",
"cluster": "development",
"about": {
"description": "",
"favorite": false
},
"creator": {
"id": "5b9c2a77b6393d0001eb45fd",
"type": "account"
},
"hub_id": "5b9c2a77b6393d0001eb45fd",
"state": {
"current": "live",
"changed": "2022-09-14T21:39:03.096Z"
},
"events": {
"created": "2022-09-14T21:39:03.096Z",
"updated": "2022-09-14T21:39:03.096Z",
"deleted": "2022-09-14T21:39:03.096Z"
},
"features": {
"legacy_networking": false
},
"services": {
"discovery": {
"enable": true,
"container_id": "5b9c2a77b6393d0001eb45fd",
"high_availability": false,
"config": {}
},
"vpn": {
"enable": true,
"container_id": "5b9c2a77b6393d0001eb45fd",
"high_availability": false,
"config": {
"auth": {
"webhook": null,
"cycle_accounts": true,
"vpn_accounts": true
},
"allow_internet": true
}
},
"loadbalancer": {
"enable": true,
"container_id": "5b9c2a77b6393d0001eb45fd",
"high_availability": true,
"config": null
}
},
"private_network": {
"vxlan_tag": 6485,
"subnet": "21",
"legacy": null,
"ipv6": {
"ip": "fd00::21:0:0:0",
"cidr": "fd00::21:0:0:0/96"
}
},
"meta": {
"containers": [
{
"id": "5b9c2a77b6393d0001eb45fd",
"name": "Demo Name",
"state": {
"changed": "2020-12-29T07:42:30.378Z",
"current": "running",
"desired": "running"
},
"image": {
"id": "5b9c2a77b6393d0001eb45fd",
"service": null
},
"environment": {
"id": "5b9c2a77b6393d0001eb45fd",
"cluster": "production",
"container_subnet": "1234",
"ipv6": {
"ip": "fd00::ef1:1834:0:0",
"cidr": "fd00::ef1:1834:0:0/96"
},
"legacy": null
}
},
{
"id": "5b9c2a77b6393d0001eb45fd",
"name": "Demo Name",
"state": {
"changed": "2020-12-29T07:42:27.51Z",
"current": "running",
"desired": "running"
},
"image": {
"id": "5b9c2a77b6393d0001eb45fd",
"service": null
},
"environment": {
"id": "5b9c2a77b6393d0001eb45fd",
"cluster": "production",
"container_subnet": "1234",
"ipv6": {
"ip": "fd00::ef1:1834:0:0",
"cidr": "fd00::ef1:1834:0:0/96"
},
"legacy": null
}
}
],
"containers_count": {
"state": {
"new": 0,
"starting": 0,
"running": 8,
"stopping": 0,
"stopped": 3,
"deleting": 0,
"deleted": 0,
"reimaging": 0
},
"total": 11,
"available": 11
},
"instances_count": {
"state": {
"new": 0,
"starting": 0,
"reimaging": 0,
"running": 12,
"migrating": 0,
"stopping": 0,
"stopped": 7,
"failed": 0,
"deleting": 0,
"deleted": 0
},
"total": 19,
"available": 19
}
}
},
"includes": {
"creators": {
"accounts": {
"5b9c2a77b6393d0001eb45fd": {
"id": "5b9c2a77b6393d0001eb45fd",
"name": {
"first": "Demo",
"last": "User"
},
"email": {
"address": "demouser@gmail.com",
"added": "2022-09-14T21:39:03.096Z",
"verified": true
},
"events": {
"last_login": "2020-03-18T19:28:15.14Z"
}
}
}
}
}
}
]
}