proofboundJoin the waitlist

Partner allowlist

MongoDB Atlas IP allowlist from CI

Atlas refuses a database connection from an address that is not on the project IP access list, unless you have opened the list to the world. GitHub-hosted runners are not on that list and should not be added as 0.0.0.0/0. CI needs a stable address, a temporary entry, or a private path.

. If a provider has moved a setting, their documentation is the authority.

What Atlas checks

Each project has an IP access list. An entry is one address or one CIDR. Atlas recommends the smallest block that works, and a single address where you can. Adding any /0, including 0.0.0.0/0, emails the project. It is the setting people reach for when CI “suddenly cannot connect,” and it is the setting a review will flag.

There is a second list, easy to confuse with the first. Atlas API keys and service accounts have their own access list on the control plane. Opening that does not let a runner connect to the cluster, and opening the cluster list does not let a script call the Atlas Admin API.

Private endpoints and VPC peering are the path that avoids a public allowlist. A GitHub-hosted runner is not inside your VPC, so peering does not help it. A self-hosted runner in the peered network can use the private path and skip the public list. Everyone else is on the public IP access list.

Adding CI without opening the world

  1. 1
    Give the workflow a stable egress address. The Actions guide is the menu. Add that address, or the larger-runner CIDR if Atlas and your policy both accept a range, as its own access list entry with a comment that names the workflow.
  2. 2
    Prefer a temporary entry when a human needs access from a hotel. Atlas supports expirations. A permanent 0.0.0.0/0 is not a temporary entry.
  3. 3
    Use a database user that can do what CI must do and nothing else. The IP list and the database user are independent gates. Both should be tight.
  4. 4
    If you automate the list with the Atlas Admin API, the API key's own access list has to include the caller that edits it. That caller is often not the job that connects to the cluster.

What the access list records

Atlas authenticates the database user and checks the source address. It does not know that the user was supposed to be used only by the migration workflow. Any job that inherits the connection string and shares the egress IP is a valid client. A gateway that requires the job's OIDC token before it will dial Atlas is what binds the allowlist entry to that workflow.

Sources

Related

An access-list entry is an address. The connection should name the job.

Proofbound is in development so a workflow can reach an Atlas cluster from dedicated egress IPs, with the workload recorded and other jobs refused. The database user and TLS stay as Atlas issued them.

One email when early access opens.