Manage networks

Use cloud networks to transmit information between cloud resources and connect them.

Note that a list of networks in DoubleCloud is created automatically when you allocate a resource in an internal network or create an external network. You can select a network when you create ClickHouse® and Apache Kafka® clusters in DoubleCloud.

See the list of networks

  1. Go to the VPC service page in console.

  2. The Networks tab lists all the networks in your project.

Use the NetworkService list method

Delete networks

Before you delete a network, you need to delete all the resources located in this network.

Resources in this case are Managed ClickHouse® and Managed Service for Apache Kafka® clusters, and also virtual machines used for Transfer with the dedicated runtime.

Delete an internal network

  1. Go to the VPC service page in the console.

  2. On the Networks tab, select a network you want to delete and click Delete.

  3. In the popup window, check the confirmation box and click Delete.

Use the NetworkService delete method and pass the network ID in the network_id request parameter.

To find the network ID, get a list of networks in the project.

Delete an external network

The process of the external network deletion is similar to the deletion of an internal network. You need to delete it in the DoubleCloud console and then delete the CloudFormation stack you used to create the associated resources.

  1. Go to the VPC service page in console.

  2. On the Networks tab, select a network you want to delete and click Delete.

  3. In the popup window, check the confirmation box and click Delete.

Use the NetworkService delete method and pass the network ID in the network_id request parameter.

To find the network ID, get a list of networks in the project.

import json
import logging

import doublecloud

from doublecloud.network.v1.network_service_pb2 import DeleteNetworkRequest
from doublecloud.network.v1.network_service_pb2_grpc import NetworkServiceStub

def delete_network(sdk, network_id):
   network_service = sdk.client(NetworkServiceStub)
   return network_service.Delete(DeleteNetworkRequest(network_id=<your_network_id>))

For more in-depth examples, check out DoubleCloud API Python SDK repository .

The process is complete on the DoubleCloud side.

Now you need to go to the AWS console .

  1. Go to the CloudFormation service page.

  2. Select your stack from the list and click Delete:

    delete a stack

  3. In the popup window, click Delete stack.

This will run the stack deletion process that will purge all the stack resources - VPC with all its elements and IAM roles.

See also