MongoDB.local SF, Jan 15: See the speaker lineup & ship your AI vision faster. Use WEB50 to save 50%
Find out more >
Docs Menu
Docs Home
/ /
/ / /

AtlasNetworkPeering 사용자 지정 리소스

중요

레거시 하위 리소스는 해당 CRD 출시하다 시점부터 더 이상 사용되지 않습니다. 현재 구성이 이 리소스 정의의 하위 리소스 형식을 사용하는 경우 를 CRD로 마이그레이션.

사용자 AtlasNetworkPeering 지정 리소스 Atlas 프로젝트 에 대한 네트워크 피어링 연결 정의합니다. 네트워크 피어링 연결은 보안 강화를 위해 공용 네트워크에서 트래픽을 격리합니다.

중요

Custom Resource(사용자 정의 리소스)는 더 이상 기본적으로 객체를 삭제하지 않음

  • Atlas Kubernetes Operator 사용자 지정 리소스 구성 파일을 사용하여 Atlas 구성을 관리 하지만, Atlas Kubernetes Operator 부터는 Kubernetes 에서 삭제 사용자 지정 2.0 리소스가 더 이상 ( 기본값) Atlas 에서 삭제되지 않습니다. 대신 Atlas Kubernetes Operator Atlas 에서 해당 리소스 관리를 중지할 뿐입니다. 예시 들어, Kubernetes 에서 Custom Resource(사용자 AtlasProject 지정 리소스)를 삭제 하면 기본값 으로 Atlas Kubernetes Operator 더 이상 Atlas 에서 해당 프로젝트 자동으로 삭제하지 않습니다. 이러한 동작 변경은 우발적이거나 예기치 않은 삭제를 방지하기 위한 것입니다. 이 동작을 Atlas Kubernetes Operator 이전에 사용된 기본값 으로 되돌리는 2 방법0 등 자세한 학습 새 기본값: Atlas Kubernetes Operator 2 의 삭제0 보호 기능을 참조하세요.

    마찬가지로, Atlas Kubernetes Operator 를 사용하여 Kubernetes 의 Atlas 프로젝트 에서 팀을 제거 하는 경우 Atlas Kubernetes Atlas Kubernetes Operator 는 Atlas 에서 팀을 삭제 하지 않습니다.

  • 기본값 Atlas 구성 값을 암시적으로 사용하지 않으려면 원하는 구성 세부 정보를 명시적으로 정의하세요. 경우에 따라 Atlas 기본값을 상속하면 조정 루프가 발생하여 사용자 지정 리소스 READY 상태 달성하지 못할 수 있습니다. 예시 들어 AtlasDeployment 사용자 지정 리소스 에 원하는 자동 확장 동작을 명시적으로 정의하면 포함된 예시 와 같이 사용자 지정 리소스 의 정적 인스턴스 크기가 자동 확장이 활성화된 Atlas 배포서버 에 반복적으로 적용되지 않도록 할 수 있습니다.

    autoScaling:
    diskGB:
    enabled: true
    compute:
    enabled: true
    scaleDownEnabled: true
    minInstanceSize: M30
    maxInstanceSize: M40

Atlas Kubernetes Operator Atlas 네트워크 피어링 API 리소스를 사용하여 다음 작업 중 하나를 수행합니다.

  • 새 네트워크 피어링 연결 만듭니다.

  • 기존 네트워크 피어링 연결 업데이트합니다.

참고

네트워크 피어링 연결 하나의 프로젝트 에만 속할 수 있습니다. 여러 프로젝트에 대해 동일한 네트워크 피어링 연결 정의하려면 각 프로젝트 에 대한 사용자 지정 리소스 정의를 만듭니다.

다음 예는 AtlasNetworkPeering CRD에 대한 구성을 보여줍니다.

  • 기본 예시 구성은 상위 Atlas 프로젝트 관리 것과 동일한 Atlas Kubernetes Operator 인스턴스 로 관리 리소스 정의합니다.

  • 독립 CRD 예시 기본 예시 와 동일한 VPC 피어링 연결을 구성하지만, VPC 피어링 연결을 관리 Atlas Kubernetes Operator 인스턴스 외부에서 관리 Atlas 프로젝트 에 대해 구성합니다.

다음 예시 my-project 프로젝트 VPCAmazon Web Services VPC 간의 green-leaf-peering 연결을 정의하는 AtlasNetworkPeering 사용자 지정 리소스 보여줍니다. 상위 Atlas 프로젝트 와 동일한 Atlas Kubernetes Operator 인스턴스 에서 이 리소스 관리 하려면 externalProjectRef 대신 projectRef 로 프로젝트 식별해야 합니다.

apiVersion: atlas.mongodb.com/v1
kind: AtlasNetworkPeering
metadata:
name: green-leaf-peering
spec:
projectRef:
name: my-project
namespace: my-operator-namespace
containerRef:
id: 72a6d2a69388ba121943ae27
id: 72a6d2a69388ba121943ae27
provider: AWS
awsConfiguration:
accepterRegionName: us-east-1
awsAccountId: 389226183042
routeTableCiderBlock: 10.0.0.0/21
vpcId: vpc-abc

다음 예시 AtlasNetworkPeering 기본 예제 에 정의된 것과 동일한 VPC피어링 연결을 구성하는 독립적인 CRD를 보여줍니다. 상위 프로젝트 와 독립적으로 리소스 관리 활성화 projectRef 대신 externalProjectRef 를 사용해야 하며, 이 리소스 상위 프로젝트 에서 API 자격 증명 상속할 수 없으므로 connectionSecret 를 직접 제공해야 합니다.

apiVersion: atlas.mongodb.com/v1
kind: AtlasNetworkPeering
metadata:
name: green-leaf-peering
spec:
externalProjectRef:
projectId: 66e2f2b621571b7e69a89b66
connectionSecret:
name: atlas-connection-secret
containerRef:
id: 72a6d2a69388ba121943ae27
id: 72a6d2a69388ba121943ae27
provider: AWS
awsConfiguration:
accepterRegionName: us-east-1
awsAccountId: 389226183042
routeTableCiderBlock: 10.0.0.0/21
vpcId: vpc-abc

AtlasNetworkPeering is the Schema for the AtlasNetworkPeering API

Name
유형
설명
필수 사항

apiVersion

문자열

atlas.mongodb.com/v1

true

kind

문자열

AtlasNetworkPeering

true

metadata

객체

Refer to the Kubernetes API documentation for the fields of the metadata field.

true

spec

객체

AtlasNetworkPeeringSpec defines the target state of AtlasNetworkPeering. Validations:

  • (has(self.``externalProjectRef``) && !has(self.``projectRef``)) || (!has(self.``externalProjectRef``) && has(self.``projectRef``)): must define only one project reference through externalProjectRef or projectRef

  • (has(self.``externalProjectRef``) && has(self.``connectionSecret``)) || !has(self.``externalProjectRef``): must define a local connection secret when referencing an external project

  • (has(self.``containerRef``.name) && !has(self.``containerRef``.id)) || (!has(self.``containerRef``.name) && has(self.``containerRef``.id)): must either have a container Atlas id or Kubernetes name, but not both (or neither)

  • (self.``containerRef``.name == oldSelf.``containerRef``.name) || (!has(self.``containerRef``.name) && !has(oldSelf.``containerRef``.name)): container ref name is immutable

  • (self.``containerRef``.id == oldSelf.``containerRef``.id) || (!has(self.``containerRef``.id) && !has(oldSelf.``containerRef``.id)): container ref id is immutable

  • (self.id == oldSelf.id) || (!has(self.id) && !has(oldSelf.id)): id is immutable

거짓

status

객체

AtlasNetworkPeeringStatus is a status for the AtlasNetworkPeering Custom resource. Not the one included in the AtlasProject

거짓

AtlasNetworkPeeringSpec defines the target state of AtlasNetworkPeering.

Name
유형
설명
필수 사항

containerRef

객체

ContainerDualReference refers to a Network Container either by Kubernetes name or Atlas ID.

true

provider

열거형

Name of the cloud service provider for which you want to create the network peering service. Enum: AWS, GCP, AZURE

true

awsConfiguration

객체

AWSConfiguration is the specific AWS settings for network peering.

거짓

azureConfiguration

객체

AzureConfiguration is the specific Azure settings for network peering.

거짓

connectionSecret

객체

Name of the secret containing Atlas API private and public keys.

거짓

externalProjectRef

객체

externalProjectRef holds the parent Atlas project ID. Mutually exclusive with the "projectRef" field.

거짓

gcpConfiguration

객체

GCPConfiguration is the specific Google Cloud settings for network peering.

거짓

id

문자열

ID is the peering identifier for an already existent network peering to be managed by the operator. This field is immutable.

거짓

projectRef

객체

projectRef is a reference to the parent AtlasProject resource. Mutually exclusive with the "externalProjectRef" field.

거짓

ContainerDualReference refers to a Network Container either by Kubernetes name or Atlas ID.

Name
유형
설명
필수 사항

id

문자열

ID is the Atlas identifier of the Network Container Atlas resource this Peering Connection relies on. Use either name or ID, not both.

거짓

name

문자열

Name of the container Kubernetes resource, must be present in the same namespace. Use either name or ID, not both.

거짓

AWSConfiguration is the specific AWS settings for network peering.

Name
유형
설명
필수 사항

accepterRegionName

문자열

AccepterRegionName is the provider region name of user's vpc in AWS native region format.

true

awsAccountId

문자열

AccountID of the user's vpc.

true

routeTableCidrBlock

문자열

User VPC CIDR.

true

vpcId

문자열

AWS VPC ID.

true

AzureConfiguration is the specific Azure settings for network peering.

Name
유형
설명
필수 사항

azureDirectoryId

문자열

AzureDirectoryID is the unique identifier for an Azure AD directory.

true

azureSubscriptionId

문자열

AzureSubscriptionID is the unique identifier of the Azure subscription in which the VNet resides.

true

resourceGroupName

문자열

ResourceGroupName is the name of your Azure resource group.

true

vNetName

문자열

VNetName is name of your Azure VNet. Its applicable only for Azure.

true

Name of the secret containing Atlas API private and public keys.

externalProjectRef holds the parent Atlas project ID. Mutually exclusive with the "projectRef" field.

Name
유형
설명
필수 사항

id

문자열

ID is the Atlas project ID.

true

GCPConfiguration is the specific Google Cloud settings for network peering.

Name
유형
설명
필수 사항

gcpProjectId

문자열

User GCP Project ID. Its applicable only for GCP.

true

networkName

문자열

GCP Network Peer Name. Its applicable only for GCP.

true

projectRef is a reference to the parent AtlasProject resource. Mutually exclusive with the "externalProjectRef" field.

Name
유형
설명
필수 사항

name

문자열

Name of the Kubernetes Resource

true

namespace

문자열

Namespace of the Kubernetes Resource

거짓

AtlasNetworkPeeringStatus is a status for the AtlasNetworkPeering Custom resource. Not the one included in the AtlasProject

Name
유형
설명
필수 사항

conditions

[]object

Conditions is the list of statuses showing the current state of the Atlas Custom Resource

true

awsStatus

객체

AWSStatus contains AWS only related status information

거짓

azureStatus

객체

AzureStatus contains Azure only related status information

거짓

gcpStatus

객체

GCPStatus contains GCP only related status information

거짓

id

문자열

ID recrods the identified of the peer created by Atlas

거짓

observedGeneration

integer

ObservedGeneration indicates the generation of the resource specification of which the Atlas Operator is aware. The Atlas Operator updates this field to the value of 'metadata.generation' as soon as it starts reconciliation of the resource. Format: int64

거짓

status

문자열

Status describes the last status seen for the network peering setup

거짓

Condition describes the state of an Atlas Custom Resource at a certain point.

Name
유형
설명
필수 사항

status

문자열

Status of the condition; one of True, False, Unknown.

true

type

문자열

Type of Atlas Custom Resource condition.

true

lastTransitionTime

문자열

Last time the condition transitioned from one status to another. Represented in ISO 8601 format. Format: date-time

거짓

message

문자열

A message providing details about the transition.

거짓

reason

문자열

The reason for the condition's last transition.

거짓

AWSStatus contains AWS only related status information

Name
유형
설명
필수 사항

connectionId

문자열

ConnectionID is the AWS VPC peering connection ID

거짓

vpcId

문자열

VpcID is AWS VPC id on the Atlas side

거짓

AzureStatus contains Azure only related status information

Name
유형
설명
필수 사항

azureSubscriptionIDpcId

문자열

AzureSubscriptionID is Azure Subscription id on the Atlas side

거짓

vNetName

문자열

VnetName is Azure network on the Atlas side

거짓

GCPStatus contains GCP only related status information

Name
유형
설명
필수 사항

gcpProjectID

문자열

GCPProjectID is GCP project on the Atlas side

거짓

networkName

문자열

NetworkName is GCP network on the Atlas side

거짓

돌아가기

AtlasNetworkContainer

이 페이지의 내용