Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kokoro Presubmit Configs for the Ops Agent UAP Plugin - Debian 12 x86_64 only #1880

Merged
merged 3 commits into from
Feb 10, 2025

Conversation

XuechunHou
Copy link
Contributor

@XuechunHou XuechunHou commented Feb 10, 2025

Description

I want to run the Ops Agent integration tests twice in presubmits for each operating system distribution and architecture: once against the regular Ops Agent and once against the Ops Agent UAP Plugin.

Therefore, I created a copy of the Kokoro presubmit configuration for Debian 12 x86_64 for the plugin. The configuration for the UAP plugin differs only in the setting of an environment variable: IS_OPS_AGENT_UAP_PLUGIN.

The Ops Agent integration tests will be refactored to check for the existence of this environment variable (see pending PR: 1a5c2e3#diff-15aa7b63bef361b26153f2363594f57d087e3def692df377b4d45423b0ec42c1R1054).

If IS_OPS_AGENT_UAP_PLUGIN is set, the tests will install the Ops Agent plugin and run against it. If not set, the tests will run against the regular Ops Agent.

Related issue

b/381246351

How has this been tested?

Checklist:

  • Unit tests
    • Unit tests do not apply.
    • Unit tests have been added/modified and passed for this PR.
  • Integration tests
    • Integration tests do not apply.
    • Integration tests have been added/modified and passed for this PR.
  • Documentation
    • This PR introduces no user visible changes.
    • This PR introduces user visible changes and the corresponding documentation change has been made.
  • Minor version bump
    • This PR introduces no new features.
    • This PR introduces new features, and there is a separate PR to bump the minor version since the last release already.
    • This PR bumps the version.

@XuechunHou XuechunHou changed the title Added Kokoro Presubmit Configs for the Ops Agent UAP Plugin Kokoro Presubmit Configs for the Ops Agent UAP Plugin - Debian 12 x86_64 only Feb 10, 2025
@XuechunHou XuechunHou self-assigned this Feb 10, 2025
environment {
TARGET = 'bookworm'
ARCH = 'x86_64'
IS_OPS_AGENT_UAP_PLUGIN = 'true'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't IS_OPS_AGENT_UAP_PLUGIN in the test files defined by checking if there's a GCS link passed in? Or is this a different variable?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The plan has changed a little. I've updated my design according to Rafael's PR: 5770e42

In Rafael's PR, the plugin tarball is uploaded to the same GCS bucket where the built regular Ops Agent package is stored. The GCS bucket is pointed to by the env variable AGENT_PACKAGES_IN_GCS: https://github.com/GoogleCloudPlatform/ops-agent/blob/master/integration_test/agents/agents.go#L699

Essentially the test has access to both the regular Ops Agent build, and the plugin tarball, but they are located under different path: 5770e42#diff-15aa7b63bef361b26153f2363594f57d087e3def692df377b4d45423b0ec42c1 (/tmp/agentUpload VS /tmp/agentPlugin)

I am still going to add an env variable (IS_OPS_AGENT_UAP_PLUGIN ) to tell the test which Ops agent it should run against. When IS_OPS_AGENT_UAP_PLUGIN is set, the test is going to install the Ops Agent tarball from /tmp/agentPlugin, otherwise the test accesses the regular Ops agent build downloaded at /tmp/agentUpload.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@XuechunHou XuechunHou merged commit 6dae7aa into master Feb 10, 2025
65 of 68 checks passed
@XuechunHou XuechunHou deleted the ida-uap-kokoro-presubmit branch February 10, 2025 21:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants