2.6.0 (latest) 2.5.0 2.4.0 2.3.0 2.2.0 2.1.0 2.0.0 1.1.0 1.0.0

    public sealed class Environment : IMessage<Environment>, IEquatable<Environment>, IDeepCloneable<Environment>, IBufferMessage, IMessage

Reference documentation and code samples for the Cloud Shell v1 API class Environment.

A Cloud Shell environment, which is defined as the combination of a Docker
image specifying what is installed on the environment and a home directory
containing the user's data that will remain across sessions. Each user has
at least an environment with the ID "default".

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> Environment

## Implements

[IMessage](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.md.txt)[Environment](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Shell.V1/latest/Google.Cloud.Shell.V1.Environment.md.txt), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[Environment](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Shell.V1/latest/Google.Cloud.Shell.V1.Environment.md.txt), [IDeepCloneable](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.md.txt)[Environment](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Shell.V1/latest/Google.Cloud.Shell.V1.Environment.md.txt), [IBufferMessage](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.md.txt), [IMessage](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.md.txt)

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.Shell.V1](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Shell.V1/latest/Google.Cloud.Shell.V1.md.txt)

## Assembly

Google.Cloud.Shell.V1.dll

## Constructors

### Environment()

    public Environment()

### Environment(Environment)

    public Environment(Environment other)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `other` | `Environment` |

## Properties

### DockerImage

    public string DockerImage { get; set; }

Required. Immutable. Full path to the Docker image used to run this environment, e.g.
"gcr.io/dev-con/cloud-devshell:latest".

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### EnvironmentName

    public EnvironmentName EnvironmentName { get; set; }

[EnvironmentName](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Shell.V1/latest/Google.Cloud.Shell.V1.EnvironmentName.md.txt)-typed view over the [Name](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Shell.V1/latest/Google.Cloud.Shell.V1.Environment.md.txt#Google_Cloud_Shell_V1_Environment_Name) resource name property.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `EnvironmentName` |   |

### Id

    public string Id { get; set; }

Output only. The environment's identifier, unique among the user's
environments.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### Name

    public string Name { get; set; }

Immutable. Full name of this resource, in the format
`users/{owner_email}/environments/{environment_id}`. `{owner_email}` is the
email address of the user to whom this environment belongs, and
`{environment_id}` is the identifier of this environment. For example,
`users/someone@example.com/environments/default`.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### PublicKeys

    public RepeatedField<string> PublicKeys { get; }

Output only. Public keys associated with the environment. Clients can
connect to this environment via SSH only if they possess a private key
corresponding to at least one of these public keys. Keys can be added to or
removed from the environment using the AddPublicKey and RemovePublicKey
methods.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `RepeatedFieldstring` |   |

### SshHost

    public string SshHost { get; set; }

Output only. Host to which clients can connect to initiate SSH sessions
with the environment.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### SshPort

    public int SshPort { get; set; }

Output only. Port to which clients can connect to initiate SSH sessions
with the environment.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `int` |   |

### SshUsername

    public string SshUsername { get; set; }

Output only. Username that clients should use when initiating SSH sessions
with the environment.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### State

    public Environment.Types.State State { get; set; }

Output only. Current execution state of this environment.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `EnvironmentTypesState` |   |

### WebHost

    public string WebHost { get; set; }

Output only. Host to which clients can connect to initiate HTTPS or WSS
connections with the environment.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `string` |   |