# ContainerNetworkAliasAnnotation Properties

- Package: [Aspire.Hosting](/reference/api/csharp/aspire.hosting.md)
- Type: [ContainerNetworkAliasAnnotation](/reference/api/csharp/aspire.hosting/containernetworkaliasannotation.md)
- Kind: `Properties`
- Members: `2`

Represents an annotation for a custom network alias for a container resource.

## Alias

- Name: `Alias`
- Modifiers: `get`
- Returns: `string`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/a3766e994fd2cba86c8ac60b8a80268cab7e6383/src/Aspire.Hosting/ApplicationModel/ContainerNetworkAliasAnnotation.cs#L33)

Gets the network alias for the container.

```csharp
public string Alias { get; }
```

## Network

- Name: `Network`
- Modifiers: `get; set`
- Returns: [NetworkIdentifier](/reference/api/csharp/aspire.hosting/networkidentifier.md)
- Source: [GitHub](https://github.com/microsoft/aspire/blob/a3766e994fd2cba86c8ac60b8a80268cab7e6383/src/Aspire.Hosting/ApplicationModel/ContainerNetworkAliasAnnotation.cs)

Gets or sets the network identifier for the network to which the alias applies.

```csharp
public NetworkIdentifier Network { get; set; }
```

## Remarks

If not specified, defaults to the default Aspire container network.
