1

I have an IBM Cloud Code Engine project with a deployed container app. That app needs to access a protected resource. I need to configure an allowlist and add the IP address(es) for the app.

How do I find those IP addresses? Is there an official list?

data_henrik
  • 16,724
  • 2
  • 28
  • 49

1 Answers1

3

I found the following API function for IBM Cloud Code Engine to list egress IP addresses.

In a shell and with the IBM Cloud CLI with Code Engine plugin, I performed the following steps:

  • log in to IBM Cloud
  • ibmcloud iam oauth-tokens --output json to obtain the access token
  • ibmcloud ce project list to obtain the Code Engine project ID and region of my project
  • curl -X GET "https://api.REGION.codeengine.cloud.ibm.com/v2/projects/PROJECT_ID/egress_ips" -H "Authorization: Bearer TOKEN" replace the parameters and call the API function

The list of returned IP addresses needs to be added in the allowlist.

data_henrik
  • 16,724
  • 2
  • 28
  • 49