You can use Cloud SDK with the command gcloud compute addresses list - list addresses to get that list, as the following Official GCP’s Documentation says. Examples:
$ gcloud compute addresses list --uri
$ gcloud compute addresses list --global
$ gcloud compute addresses list --filter=region:us-central1
A second option is to set up an Uptime Check following this url’s steps and then verify the List uptime-check server IP addresses, as the following enter link description here indicates. Here is an example of the code to create the Uptime Check:
public static object CreateUptimeCheck(string projectId, string hostName,
string displayName)
{
// Define a new config.
var config = new UptimeCheckConfig()
{
DisplayName = displayName,
MonitoredResource = new MonitoredResource()
{
Type = "uptime_url",
Labels = { { "host", hostName } }
},
HttpCheck = new UptimeCheckConfig.Types.HttpCheck()
{
Path = "/",
Port = 80,
},
Timeout = TimeSpan.FromSeconds(10).ToDuration(),
Period = TimeSpan.FromMinutes(5).ToDuration()
};
// Create a client.
var client = UptimeCheckServiceClient.Create();
ProjectName projectName = new ProjectName(projectId);
// Create the config.
var newConfig = client.CreateUptimeCheckConfig(
projectName,
config,
CallSettings.FromExpiration(
Expiration.FromTimeout(
TimeSpan.FromMinutes(2))));
Console.WriteLine(newConfig.Name);
return 0;
}
And the steps to list the IP addresses, once the Uptime Check is running:
In the Cloud Console, select Monitoring or click the following button.
In the navigation pane, select Uptime checks.
In the Uptime checks menu, click Download get_app. A file uptime-source-ips.txt is downloaded and contains the IP addresses.
There is no monitoring tool available right now inside of Cloud Monitoring yet.