Introduction

Google Cloud Platform (GCP), is a suite of cloud computing services that runs on the same infrastructure that Google uses internally for its end-user products.

Prerequisites

  • Service Account Management Certificate (JSON or P12 key/credentials)
  • Management Certificate PassPhrase

GCP configuration for event-based discovery (optional)

OpsRamp supports the instant discovery of Google Cloud Platform (GCP) events, as and when the events are created.

Event-based discovery helps discover resources in real-time by streaming create and delete event actions between GCP and OpsRamp.

Event-based discovery is implemented by subscribing to the events. Once subscribed, event notification occurs.

Configuring event discovery involves:

  1. Creating topics that correspond to events.
  2. Creating subscriptions for topics.
  3. Creating exports

Prerequisites and considerations

  • A project must be created in GCP.
  • The Cloud Pub/Sub API must be enabled for the project.
  • A subscription created for an event must be used for only one Google Cloud integration in OpsRamp.

Step 1: Create a topic

Topics receive messages sent by publishers corresponding to the events.

To create a topic:

  1. Log into GCP as administrator.
  2. From Navigation Menu, go to Big Data > Pub/Sub, and click Create Topic
  3. Provide a topic name and click CREATE. The topic you created appears in the topics list.
Create a Topic

Create a Topic

Step 2: Create a subscription

Subscription represents the stream of messages from a single, specific topic, to be delivered to the subscribing application.

To create a subscription for the topic:

  1. From the Topics list, click the topic you created.
  2. From Subscriptions, click CREATE SUBSCRIPTION.
  3. Provide the following details and click Create.
    • Subscription name: Provide a name
    • Delivery Type: Pull
    • Acknowledgment Deadline: 600 (Recommended)
Create a Subscription

Create a Subscription

Step 3: Create an export

To create an export:

  1. Go to Stack Driver > Logging and click CREATE EXPORT.
  2. Expand the Filter options and select Convert to advanced filter.
  3. Provide the following:
    • Sink Service: pub/sub
    • Sink destination: Name of the topic you created Filter: severity=NOTICE (Mandatory)
  4. Click Create Sink. Events matching the filter criteria are sent to the sink (pub/sub topic).
Create an Export

Create an Export

OpsRamp configuration

Configuration involves:

  1. Configuring the integration.
  2. Adding a discovery profile.

Step 1: Configure the integration

To integrate:

  1. From All Clients, select a client.
  2. Go to Setup > Integrations > Integrations.
  3. From Available Integrations, select Public Cloud > Google and click Install.
  4. Provide the following:
    • Name
    • Service Account Email
    • Project Id
    • Service Account Management Certificate
    • Management Certificate PassPhrase
  5. Click Install.

Step 2: Add a discovery profile

To add a discovery profile:

  1. From the integration, click Add.
  2. Provide the following:
    • Profile Details.
      • Profile name
    • Filter Criteria
      • Smart filters: Use to filter resources based on the resource type.
      • Resource filters: Use to filter resources based on certain resource attributes.
    • Perform Actions:
      • Manage Device
      • Collect Cost Analytics: Provide GCP bucket name.
        This option collects project cost details for the services and resources utilized.
        GCP Bucket Name for Collect Cost Analytics

        GCP Bucket Name for Collect Cost Analytics

      • Stream Google Events.
      • Assign Gateway Management Profile
    • Perform Agent Action
      • Agent Type: Direct or Proxy. If Proxy, select gateway profile.
      • Install Agent (Linux only)
    • Discovery schedule. Based on the settings, discovery is triggered based on the scheduled time. New resources added to the environment are automatically discovered.
  3. Click Save.
  4. From the Discovery Profiles section, click Scan Now for the associated profile.