IBM Cloud Docs
Service Endpoints Integration

Service Endpoints Integration

All Cloud Databases deployments offer integration with IBM Cloud Service Endpoints to enable connections to your deployments from the public internet and over the IBM Cloud Private network.

Service Endpoints are available in all IBM Cloud Multi-Zone Regions and some single-campus multizone regions. Deployments in all other regions are able to use Service Endpoints.

Public Endpoints

Public endpoints provide a connection to your deployment on the public network. At provision, a public endpoint is the default option for all deployments. Your environment needs to have internet access to connect to a deployment.

For enhanced security, it is recommended that users connect to their Cloud Databases deployments using private endpoints instead of public endpoints.

Private Endpoints

A deployment with a service endpoint on the private network gets an endpoint that is not accessible from the public internet. All traffic is routed to hardware dedicated to Cloud Databases deployments and remains on the IBM Cloud Private network. All traffic to and from this endpoint is free and unmetered on the condition that the traffic remains in IBM Cloud. After your environment has access to the IBM Cloud Private network, an internet connection is not required to connect to your deployment.

For more information, see Secure access to services using service endpoints.

Deployments with private endpoints are reachable from any account within the private network and access to each instance requires authentication. To restrict this access to specific IP addresses, or ranges of IP addresses, configure Context-based restrictions.

Enabling Service Endpoints

To use connections over the public internet, you do not have to enable Service Endpoints on your IBM Cloud account. To enable private networking on your deployments, follow the instructions at Enabling VRF and service endpoints.

Currently, enabling virtual routing and forwarding (VRF) on your account in classic is a manual step that is handled by support ticket. VRF is automatically enabled for VPC. After you complete the request, check on the status of the ticket by going to your Support page on IBM Cloud.

Provisioning with Service Endpoints through the UI

To configure your deployment's endpoints on provision, use the Endpoints field on the catalog page. Select from the available options:

  • Public Network
  • Private Network
  • Both public and private network

A MongoDB deployment cannot support both public and private endpoints simultaneously. This cannot be changed after provisioning.

Provisioning with Service Endpoints through the CLI

Service Endpoints are enabled through an optional parameter when you provision through the CLI. Provisioning is handled by the Resource Controller. Pass the service-endpoints parameter one of the options public, private, or public-and-private.

ibmcloud resource service-instance-create <service-name> --service-endpoints <endpoint-type>

Cloud Databases deployments except Databases for MongoDB allow for both public and private networking to be enabled at the same time.

Provisioning with Service Endpoints through the API

Service Endpoints are enabled through an optional parameter when you provision through the API. Provisioning is handled by the Resource Controller. Pass the service-endpoints parameter one of the options public, private, or public-and-private.

ibmcloud resource service-instance-create <service-name> --service-endpoints <endpoint-type>

Cloud Databases deployments except Databases for MongoDB allow for both public and private networking to be enabled at the same time.

Changing Service Endpoints

After you deploy, it is possible to change your public and private service endpoints configuration, except for Databases for MongoDB.

Changing Service Endpoints through the UI

In the Overview tab of your deployment's dashboard, go to the Endpoints section. Toggle which types of connections are available to your deployment.

Changing the type of endpoints available on your deployment does not cause any downtime from a database perspective. However, if you disable an endpoint that is being used by you or your applications, those connections are dropped.

Changing Service Endpoints through the CLI

Use the ibmcloud resource service-instance-update command in the CLI, specifying the endpoint with the --service-endpoints flag.

ibmcloud resource service-instance-update <service-name> --service-endpoints <endpoint-type>

Changing the type of endpoints available on your deployment does not cause any downtime from a database perspective. However, if you disable an endpoint that is being used by you or your applications, those connections are dropped.

Changing Service Endpoints through the API

Use the Resource Controller API, with a PATCH request to the /resource_instances/{id} endpoint.

Changing the type of endpoints available on your deployment does not cause any downtime from a database perspective. However, if you disable an endpoint that is being used by you or your applications, those connections are dropped.

Credentials for Private Endpoints

Use either public or private connection strings with any set of credentials that you make on your deployment. By default, the connection strings for a set of credentials are filled with strings for connecting over a public endpoint. If you are using private endpoints, specify connection strings that contain the private endpoint be generated instead.

When you create credentials in the Service Credentials UI, use either the { "service-endpoints": "public" } or the { "service-endpoints": "private" } parameter to specify which endpoint gets filled into the connection strings.

In the API, use the /deployments/{id}/users/{userid}/connections/{endpoint_type} to retrieve connection strings for both public or private endpoints.

If you have only private endpoints on your deployments, then all new credentials have private endpoints in the connection strings.

Connecting Through Private Endpoints

Cloud Databases offers both private and public cloud service endpoints. To run your application or access the end point from a browser that is not on the private network, take these additional steps:

  • Ensure your Cloud IaaS or SL account is enabled for private endpoints.
  • Create a virtual machine (VSI) that runs Linux.
  • Configure a user account with SSH access.
  • From your workstation, run ssh -D 2345 user@vsi-host to start an SSH session and open a SOCKS proxy on port 2345 that forwards all traffic through the VSI.
  • Configure your browser or application to use a SOCKS5 proxy on localhost:2345.
  • Run your application or open the preferred private-endpoint in your browser (for example, a management UI).

Using Virtual Private Endpoints

For more information, see Virtual Private Endpoints.