mongodb / mongodb-atlas-kubernetes

MongoDB Atlas Kubernetes Operator - Manage your MongoDB Atlas clusters from Kubernetes
http://www.mongodb.com/cloud/atlas
Apache License 2.0
149 stars 76 forks source link

Support for cross-region cluster #279

Closed alex-tw-lam closed 2 years ago

alex-tw-lam commented 3 years ago

Disaster recovery is a capability required by many enterprises. we want to be able to create clusters within the atlas operator with DR enabled by default.

leo-ri commented 3 years ago

Hi @alex-tw-lam Cross-region cluster is supported right now, here's a sample:

apiVersion: atlas.mongodb.com/v1
kind: AtlasCluster
metadata:
  name: atlascluster-multiregion-azure
spec:
  name: cluster-multiregion-azure
  projectRef:
    name: my-project
  providerBackupEnabled: true
  clusterType: REPLICASET
  providerSettings:
    instanceSizeName: M10
    providerName: AZURE
  replicationSpecs:
  - numShards: 1
    zoneName: Europe
    regionsConfig:
      NORWAY_EAST:
        analyticsNodes: 0
        electableNodes: 1
        priority: 6
        readOnlyNodes: 0
      GERMANY_NORTH:
        analyticsNodes: 0
        electableNodes: 2
        priority: 7
        readOnlyNodes: 0

if there are any issues and it is not working for you, please, send logs, and yours configs

list of regions: https://docs.atlas.mongodb.com/cloud-providers-regions/