Documentation ¶
Overview ¶
Package osconfig provides access to the OS Config API.
For product documentation, see: https://cloud.google.com/compute/docs/osconfig/rest
Creating a client ¶
Usage example:
import "google.golang.org/api/osconfig/v1alpha" ... ctx := context.Background() osconfigService, err := osconfig.NewService(ctx)
In this example, Google Application Default Credentials are used for authentication.
For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
Other authentication options ¶
To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
osconfigService, err := osconfig.NewService(ctx, option.WithAPIKey("AIza..."))
To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
config := &oauth2.Config{...} // ... token, err := config.Exchange(ctx, ...) osconfigService, err := osconfig.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
See https://godoc.org/google.golang.org/api/option/ for details on options.
Index ¶
- Constants
- type CVSSv3
- type CancelOperationRequest
- type Empty
- type FixedOrPercent
- type InstanceOSPoliciesCompliance
- type InstanceOSPoliciesComplianceOSPolicyCompliance
- type Inventory
- type InventoryItem
- type InventoryOsInfo
- type InventorySoftwarePackage
- type InventoryVersionedPackage
- type InventoryWindowsQuickFixEngineeringPackage
- type InventoryWindowsUpdatePackage
- type InventoryWindowsUpdatePackageWindowsUpdateCategory
- type InventoryZypperPatch
- type ListInstanceOSPoliciesCompliancesResponse
- type ListInventoriesResponse
- type ListOSPolicyAssignmentRevisionsResponse
- type ListOSPolicyAssignmentsResponse
- type ListVulnerabilityReportsResponse
- type OSPolicy
- type OSPolicyAssignment
- type OSPolicyAssignmentInstanceFilter
- type OSPolicyAssignmentLabelSet
- type OSPolicyAssignmentOperationMetadata
- type OSPolicyAssignmentRollout
- type OSPolicyOSFilter
- type OSPolicyResource
- type OSPolicyResourceCompliance
- type OSPolicyResourceComplianceExecResourceOutput
- type OSPolicyResourceConfigStep
- type OSPolicyResourceExecResource
- type OSPolicyResourceExecResourceExec
- type OSPolicyResourceFile
- type OSPolicyResourceFileGcs
- type OSPolicyResourceFileRemote
- type OSPolicyResourceFileResource
- type OSPolicyResourceGroup
- type OSPolicyResourcePackageResource
- type OSPolicyResourcePackageResourceAPT
- type OSPolicyResourcePackageResourceDeb
- type OSPolicyResourcePackageResourceGooGet
- type OSPolicyResourcePackageResourceMSI
- type OSPolicyResourcePackageResourceRPM
- type OSPolicyResourcePackageResourceYUM
- type OSPolicyResourcePackageResourceZypper
- type OSPolicyResourceRepositoryResource
- type OSPolicyResourceRepositoryResourceAptRepository
- type OSPolicyResourceRepositoryResourceGooRepository
- type OSPolicyResourceRepositoryResourceYumRepository
- type OSPolicyResourceRepositoryResourceZypperRepository
- type Operation
- type ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Context(ctx context.Context) *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Do(opts ...googleapi.CallOption) (*InstanceOSPoliciesCompliance, error)
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Header() http.Header
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
- type ProjectsLocationsInstanceOSPoliciesCompliancesListCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Context(ctx context.Context) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Do(opts ...googleapi.CallOption) (*ListInstanceOSPoliciesCompliancesResponse, error)
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Filter(filter string) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Header() http.Header
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) PageSize(pageSize int64) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) PageToken(pageToken string) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
- func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Pages(ctx context.Context, f func(*ListInstanceOSPoliciesCompliancesResponse) error) error
- type ProjectsLocationsInstanceOSPoliciesCompliancesService
- type ProjectsLocationsInstancesInventoriesGetCall
- func (c *ProjectsLocationsInstancesInventoriesGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesInventoriesGetCall
- func (c *ProjectsLocationsInstancesInventoriesGetCall) Do(opts ...googleapi.CallOption) (*Inventory, error)
- func (c *ProjectsLocationsInstancesInventoriesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesInventoriesGetCall
- func (c *ProjectsLocationsInstancesInventoriesGetCall) Header() http.Header
- func (c *ProjectsLocationsInstancesInventoriesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesInventoriesGetCall
- func (c *ProjectsLocationsInstancesInventoriesGetCall) View(view string) *ProjectsLocationsInstancesInventoriesGetCall
- type ProjectsLocationsInstancesInventoriesListCall
- func (c *ProjectsLocationsInstancesInventoriesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesInventoriesListCall
- func (c *ProjectsLocationsInstancesInventoriesListCall) Do(opts ...googleapi.CallOption) (*ListInventoriesResponse, error)
- func (c *ProjectsLocationsInstancesInventoriesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesInventoriesListCall
- func (c *ProjectsLocationsInstancesInventoriesListCall) Filter(filter string) *ProjectsLocationsInstancesInventoriesListCall
- func (c *ProjectsLocationsInstancesInventoriesListCall) Header() http.Header
- func (c *ProjectsLocationsInstancesInventoriesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesInventoriesListCall
- func (c *ProjectsLocationsInstancesInventoriesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesInventoriesListCall
- func (c *ProjectsLocationsInstancesInventoriesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesInventoriesListCall
- func (c *ProjectsLocationsInstancesInventoriesListCall) Pages(ctx context.Context, f func(*ListInventoriesResponse) error) error
- func (c *ProjectsLocationsInstancesInventoriesListCall) View(view string) *ProjectsLocationsInstancesInventoriesListCall
- type ProjectsLocationsInstancesInventoriesService
- type ProjectsLocationsInstancesService
- type ProjectsLocationsInstancesVulnerabilityReportsGetCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesVulnerabilityReportsGetCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Do(opts ...googleapi.CallOption) (*VulnerabilityReport, error)
- func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesVulnerabilityReportsGetCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Header() http.Header
- func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesVulnerabilityReportsGetCall
- type ProjectsLocationsInstancesVulnerabilityReportsListCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Context(ctx context.Context) *ProjectsLocationsInstancesVulnerabilityReportsListCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Do(opts ...googleapi.CallOption) (*ListVulnerabilityReportsResponse, error)
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesVulnerabilityReportsListCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Filter(filter string) *ProjectsLocationsInstancesVulnerabilityReportsListCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Header() http.Header
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesVulnerabilityReportsListCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesVulnerabilityReportsListCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) PageToken(pageToken string) *ProjectsLocationsInstancesVulnerabilityReportsListCall
- func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Pages(ctx context.Context, f func(*ListVulnerabilityReportsResponse) error) error
- type ProjectsLocationsInstancesVulnerabilityReportsService
- type ProjectsLocationsOsPolicyAssignmentsCreateCall
- func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsCreateCall
- func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsCreateCall
- func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Header() http.Header
- func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) OsPolicyAssignmentId(osPolicyAssignmentId string) *ProjectsLocationsOsPolicyAssignmentsCreateCall
- type ProjectsLocationsOsPolicyAssignmentsDeleteCall
- func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsDeleteCall
- func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsDeleteCall
- func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Header() http.Header
- type ProjectsLocationsOsPolicyAssignmentsGetCall
- func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsGetCall
- func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Do(opts ...googleapi.CallOption) (*OSPolicyAssignment, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsGetCall
- func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Header() http.Header
- func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsGetCall
- type ProjectsLocationsOsPolicyAssignmentsListCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsListCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Do(opts ...googleapi.CallOption) (*ListOSPolicyAssignmentsResponse, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsListCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Header() http.Header
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsListCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) PageSize(pageSize int64) *ProjectsLocationsOsPolicyAssignmentsListCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) PageToken(pageToken string) *ProjectsLocationsOsPolicyAssignmentsListCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Pages(ctx context.Context, f func(*ListOSPolicyAssignmentsResponse) error) error
- type ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Do(opts ...googleapi.CallOption) (*ListOSPolicyAssignmentRevisionsResponse, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Header() http.Header
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) PageSize(pageSize int64) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) PageToken(pageToken string) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
- func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Pages(ctx context.Context, f func(*ListOSPolicyAssignmentRevisionsResponse) error) error
- type ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Header() http.Header
- type ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Header() http.Header
- func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
- type ProjectsLocationsOsPolicyAssignmentsOperationsService
- func (r *ProjectsLocationsOsPolicyAssignmentsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall
- func (r *ProjectsLocationsOsPolicyAssignmentsOperationsService) Get(name string) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
- type ProjectsLocationsOsPolicyAssignmentsPatchCall
- func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsPatchCall
- func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsPatchCall
- func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Header() http.Header
- func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsOsPolicyAssignmentsPatchCall
- type ProjectsLocationsOsPolicyAssignmentsService
- func (r *ProjectsLocationsOsPolicyAssignmentsService) Create(parent string, ospolicyassignment *OSPolicyAssignment) *ProjectsLocationsOsPolicyAssignmentsCreateCall
- func (r *ProjectsLocationsOsPolicyAssignmentsService) Delete(name string) *ProjectsLocationsOsPolicyAssignmentsDeleteCall
- func (r *ProjectsLocationsOsPolicyAssignmentsService) Get(name string) *ProjectsLocationsOsPolicyAssignmentsGetCall
- func (r *ProjectsLocationsOsPolicyAssignmentsService) List(parent string) *ProjectsLocationsOsPolicyAssignmentsListCall
- func (r *ProjectsLocationsOsPolicyAssignmentsService) ListRevisions(name string) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
- func (r *ProjectsLocationsOsPolicyAssignmentsService) Patch(name string, ospolicyassignment *OSPolicyAssignment) *ProjectsLocationsOsPolicyAssignmentsPatchCall
- type ProjectsLocationsService
- type ProjectsService
- type Service
- type Status
- type VulnerabilityReport
- type VulnerabilityReportVulnerability
- type VulnerabilityReportVulnerabilityDetails
- type VulnerabilityReportVulnerabilityDetailsReference
Constants ¶
const (
// See, edit, configure, and delete your Google Cloud Platform data
CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
)
OAuth2 scopes used by this API.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CVSSv3 ¶
type CVSSv3 struct { // AttackComplexity: This metric describes the conditions beyond the // attacker's control that must exist in order to exploit the // vulnerability. // // Possible values: // "ATTACK_COMPLEXITY_UNSPECIFIED" - Invalid value. // "ATTACK_COMPLEXITY_LOW" - Specialized access conditions or // extenuating circumstances do not exist. An attacker can expect // repeatable success when attacking the vulnerable component. // "ATTACK_COMPLEXITY_HIGH" - A successful attack depends on // conditions beyond the attacker's control. That is, a successful // attack cannot be accomplished at will, but requires the attacker to // invest in some measurable amount of effort in preparation or // execution against the vulnerable component before a successful attack // can be expected. AttackComplexity string `json:"attackComplexity,omitempty"` // AttackVector: This metric reflects the context by which vulnerability // exploitation is possible. // // Possible values: // "ATTACK_VECTOR_UNSPECIFIED" - Invalid value. // "ATTACK_VECTOR_NETWORK" - The vulnerable component is bound to the // network stack and the set of possible attackers extends beyond the // other options listed below, up to and including the entire Internet. // "ATTACK_VECTOR_ADJACENT" - The vulnerable component is bound to the // network stack, but the attack is limited at the protocol level to a // logically adjacent topology. // "ATTACK_VECTOR_LOCAL" - The vulnerable component is not bound to // the network stack and the attacker's path is via read/write/execute // capabilities. // "ATTACK_VECTOR_PHYSICAL" - The attack requires the attacker to // physically touch or manipulate the vulnerable component. AttackVector string `json:"attackVector,omitempty"` // AvailabilityImpact: This metric measures the impact to the // availability of the impacted component resulting from a successfully // exploited vulnerability. // // Possible values: // "IMPACT_UNSPECIFIED" - Invalid value. // "IMPACT_HIGH" - High impact. // "IMPACT_LOW" - Low impact. // "IMPACT_NONE" - No impact. AvailabilityImpact string `json:"availabilityImpact,omitempty"` // BaseScore: The base score is a function of the base metric scores. // https://www.first.org/cvss/specification-document#Base-Metrics BaseScore float64 `json:"baseScore,omitempty"` // ConfidentialityImpact: This metric measures the impact to the // confidentiality of the information resources managed by a software // component due to a successfully exploited vulnerability. // // Possible values: // "IMPACT_UNSPECIFIED" - Invalid value. // "IMPACT_HIGH" - High impact. // "IMPACT_LOW" - Low impact. // "IMPACT_NONE" - No impact. ConfidentialityImpact string `json:"confidentialityImpact,omitempty"` // ExploitabilityScore: The Exploitability sub-score equation is derived // from the Base Exploitability metrics. // https://www.first.org/cvss/specification-document#2-1-Exploitability-Metrics ExploitabilityScore float64 `json:"exploitabilityScore,omitempty"` // ImpactScore: The Impact sub-score equation is derived from the Base // Impact metrics. ImpactScore float64 `json:"impactScore,omitempty"` // IntegrityImpact: This metric measures the impact to integrity of a // successfully exploited vulnerability. // // Possible values: // "IMPACT_UNSPECIFIED" - Invalid value. // "IMPACT_HIGH" - High impact. // "IMPACT_LOW" - Low impact. // "IMPACT_NONE" - No impact. IntegrityImpact string `json:"integrityImpact,omitempty"` // PrivilegesRequired: This metric describes the level of privileges an // attacker must possess before successfully exploiting the // vulnerability. // // Possible values: // "PRIVILEGES_REQUIRED_UNSPECIFIED" - Invalid value. // "PRIVILEGES_REQUIRED_NONE" - The attacker is unauthorized prior to // attack, and therefore does not require any access to settings or // files of the vulnerable system to carry out an attack. // "PRIVILEGES_REQUIRED_LOW" - The attacker requires privileges that // provide basic user capabilities that could normally affect only // settings and files owned by a user. Alternatively, an attacker with // Low privileges has the ability to access only non-sensitive // resources. // "PRIVILEGES_REQUIRED_HIGH" - The attacker requires privileges that // provide significant (e.g., administrative) control over the // vulnerable component allowing access to component-wide settings and // files. PrivilegesRequired string `json:"privilegesRequired,omitempty"` // Scope: The Scope metric captures whether a vulnerability in one // vulnerable component impacts resources in components beyond its // security scope. // // Possible values: // "SCOPE_UNSPECIFIED" - Invalid value. // "SCOPE_UNCHANGED" - An exploited vulnerability can only affect // resources managed by the same security authority. // "SCOPE_CHANGED" - An exploited vulnerability can affect resources // beyond the security scope managed by the security authority of the // vulnerable component. Scope string `json:"scope,omitempty"` // UserInteraction: This metric captures the requirement for a human // user, other than the attacker, to participate in the successful // compromise of the vulnerable component. // // Possible values: // "USER_INTERACTION_UNSPECIFIED" - Invalid value. // "USER_INTERACTION_NONE" - The vulnerable system can be exploited // without interaction from any user. // "USER_INTERACTION_REQUIRED" - Successful exploitation of this // vulnerability requires a user to take some action before the // vulnerability can be exploited. UserInteraction string `json:"userInteraction,omitempty"` // ForceSendFields is a list of field names (e.g. "AttackComplexity") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "AttackComplexity") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` }
CVSSv3: Common Vulnerability Scoring System version 3. For details, see https://www.first.org/cvss/specification-document
func (*CVSSv3) MarshalJSON ¶
func (*CVSSv3) UnmarshalJSON ¶
type CancelOperationRequest ¶
type CancelOperationRequest struct { }
CancelOperationRequest: The request message for Operations.CancelOperation.
type Empty ¶
type Empty struct { // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` }
Empty: A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`.
type FixedOrPercent ¶
type FixedOrPercent struct { // Fixed: Specifies a fixed value. Fixed int64 `json:"fixed,omitempty"` // Percent: Specifies the relative value defined as a percentage, which // will be multiplied by a reference value. Percent int64 `json:"percent,omitempty"` // ForceSendFields is a list of field names (e.g. "Fixed") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Fixed") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
FixedOrPercent: Message encapsulating a value that can be either absolute ("fixed") or relative ("percent") to a value.
func (*FixedOrPercent) MarshalJSON ¶
func (s *FixedOrPercent) MarshalJSON() ([]byte, error)
type InstanceOSPoliciesCompliance ¶
type InstanceOSPoliciesCompliance struct { // DetailedState: Output only. Detailed compliance state of the VM. This // field is populated only when compliance state is `UNKNOWN`. It may // contain one of the following values: * `no-compliance-data`: // Compliance data is not available for this VM. * `no-agent-detected`: // OS Config agent is not detected for this VM. * // `config-not-supported-by-agent`: The version of the OS Config agent // running on this VM does not support configuration management. * // `inactive`: VM is not running. * `internal-service-errors`: There // were internal service errors encountered while enforcing compliance. // * `agent-errors`: OS config agent encountered errors while enforcing // compliance. DetailedState string `json:"detailedState,omitempty"` // DetailedStateReason: Output only. The reason for the `detailed_state` // of the VM (if any). DetailedStateReason string `json:"detailedStateReason,omitempty"` // Instance: Output only. The Compute Engine VM instance name. Instance string `json:"instance,omitempty"` // LastComplianceCheckTime: Output only. Timestamp of the last // compliance check for the VM. LastComplianceCheckTime string `json:"lastComplianceCheckTime,omitempty"` // LastComplianceRunId: Output only. Unique identifier for the last // compliance run. This id will be logged by the OS config agent during // a compliance run and can be used for debugging and tracing purpose. LastComplianceRunId string `json:"lastComplianceRunId,omitempty"` // Name: Output only. The `InstanceOSPoliciesCompliance` API resource // name. Format: // `projects/{project_number}/locations/{location}/instanceOSPoliciesComp // liances/{instance_id}` Name string `json:"name,omitempty"` // OsPolicyCompliances: Output only. Compliance data for each `OSPolicy` // that is applied to the VM. OsPolicyCompliances []*InstanceOSPoliciesComplianceOSPolicyCompliance `json:"osPolicyCompliances,omitempty"` // State: Output only. Compliance state of the VM. // // Possible values: // "OS_POLICY_COMPLIANCE_STATE_UNSPECIFIED" - Default value. This // value is unused. // "COMPLIANT" - Compliant state. // "NON_COMPLIANT" - Non-compliant state // "UNKNOWN" - Unknown compliance state. // "NO_OS_POLICIES_APPLICABLE" - No applicable OS policies were found // for the instance. This state is only applicable to the instance. State string `json:"state,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "DetailedState") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "DetailedState") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InstanceOSPoliciesCompliance: This API resource represents the OS policies compliance data for a Compute Engine virtual machine (VM) instance at a given point in time. A Compute Engine VM can have multiple OS policy assignments, and each assignment can have multiple OS policies. As a result, multiple OS policies could be applied to a single VM. You can use this API resource to determine both the compliance state of your VM as well as the compliance state of an individual OS policy. For more information, see View compliance (https://cloud.google.com/compute/docs/os-configuration-management/view-compliance).
func (*InstanceOSPoliciesCompliance) MarshalJSON ¶
func (s *InstanceOSPoliciesCompliance) MarshalJSON() ([]byte, error)
type InstanceOSPoliciesComplianceOSPolicyCompliance ¶
type InstanceOSPoliciesComplianceOSPolicyCompliance struct { // OsPolicyAssignment: Reference to the `OSPolicyAssignment` API // resource that the `OSPolicy` belongs to. Format: // `projects/{project_number}/locations/{location}/osPolicyAssignments/{o // s_policy_assignment_id@revision_id}` OsPolicyAssignment string `json:"osPolicyAssignment,omitempty"` // OsPolicyId: The OS policy id OsPolicyId string `json:"osPolicyId,omitempty"` // OsPolicyResourceCompliances: Compliance data for each // `OSPolicyResource` that is applied to the VM. OsPolicyResourceCompliances []*OSPolicyResourceCompliance `json:"osPolicyResourceCompliances,omitempty"` // State: Compliance state of the OS policy. // // Possible values: // "OS_POLICY_COMPLIANCE_STATE_UNSPECIFIED" - Default value. This // value is unused. // "COMPLIANT" - Compliant state. // "NON_COMPLIANT" - Non-compliant state // "UNKNOWN" - Unknown compliance state. // "NO_OS_POLICIES_APPLICABLE" - No applicable OS policies were found // for the instance. This state is only applicable to the instance. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "OsPolicyAssignment") // to unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "OsPolicyAssignment") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` }
InstanceOSPoliciesComplianceOSPolicyCompliance: Compliance data for an OS policy
func (*InstanceOSPoliciesComplianceOSPolicyCompliance) MarshalJSON ¶
func (s *InstanceOSPoliciesComplianceOSPolicyCompliance) MarshalJSON() ([]byte, error)
type Inventory ¶
type Inventory struct { // Items: Output only. Inventory items related to the VM keyed by an // opaque unique identifier for each inventory item. The identifier is // unique to each distinct and addressable inventory item and will // change, when there is a new package version. Items map[string]InventoryItem `json:"items,omitempty"` // Name: Output only. The `Inventory` API resource name. Format: // `projects/{project_number}/locations/{location}/instances/{instance_id // }/inventory` Name string `json:"name,omitempty"` // OsInfo: Output only. Base level operating system information for the // VM. OsInfo *InventoryOsInfo `json:"osInfo,omitempty"` // UpdateTime: Output only. Timestamp of the last reported inventory for // the VM. UpdateTime string `json:"updateTime,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Items") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Items") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
Inventory: This API resource represents the available inventory data for a Compute Engine virtual machine (VM) instance at a given point in time. You can use this API resource to determine the inventory data of your VM. For more information, see Information provided by OS inventory management (https://cloud.google.com/compute/docs/instances/os-inventory-management#data-collected).
func (*Inventory) MarshalJSON ¶
type InventoryItem ¶
type InventoryItem struct { // AvailablePackage: Software package available to be installed on the // VM instance. AvailablePackage *InventorySoftwarePackage `json:"availablePackage,omitempty"` // CreateTime: When this inventory item was first detected. CreateTime string `json:"createTime,omitempty"` // Id: Identifier for this item, unique across items for this VM. Id string `json:"id,omitempty"` // InstalledPackage: Software package present on the VM instance. InstalledPackage *InventorySoftwarePackage `json:"installedPackage,omitempty"` // OriginType: The origin of this inventory item. // // Possible values: // "ORIGIN_TYPE_UNSPECIFIED" - Invalid. An origin type must be // specified. // "INVENTORY_REPORT" - This inventory item was discovered as the // result of the agent reporting inventory via the reporting API. OriginType string `json:"originType,omitempty"` // Type: The specific type of inventory, correlating to its specific // details. // // Possible values: // "TYPE_UNSPECIFIED" - Invalid. An type must be specified. // "INSTALLED_PACKAGE" - This represents a package that is installed // on the VM. // "AVAILABLE_PACKAGE" - This represents an update that is available // for a package. Type string `json:"type,omitempty"` // UpdateTime: When this inventory item was last modified. UpdateTime string `json:"updateTime,omitempty"` // ForceSendFields is a list of field names (e.g. "AvailablePackage") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "AvailablePackage") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` }
InventoryItem: A single piece of inventory on a VM.
func (*InventoryItem) MarshalJSON ¶
func (s *InventoryItem) MarshalJSON() ([]byte, error)
type InventoryOsInfo ¶
type InventoryOsInfo struct { // Architecture: The system architecture of the operating system. Architecture string `json:"architecture,omitempty"` // Hostname: The VM hostname. Hostname string `json:"hostname,omitempty"` // KernelRelease: The kernel release of the operating system. KernelRelease string `json:"kernelRelease,omitempty"` // KernelVersion: The kernel version of the operating system. KernelVersion string `json:"kernelVersion,omitempty"` // LongName: The operating system long name. For example 'Debian // GNU/Linux 9' or 'Microsoft Window Server 2019 Datacenter'. LongName string `json:"longName,omitempty"` // OsconfigAgentVersion: The current version of the OS Config agent // running on the VM. OsconfigAgentVersion string `json:"osconfigAgentVersion,omitempty"` // ShortName: The operating system short name. For example, 'windows' or // 'debian'. ShortName string `json:"shortName,omitempty"` // Version: The version of the operating system. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "Architecture") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Architecture") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InventoryOsInfo: Operating system information for the VM.
func (*InventoryOsInfo) MarshalJSON ¶
func (s *InventoryOsInfo) MarshalJSON() ([]byte, error)
type InventorySoftwarePackage ¶
type InventorySoftwarePackage struct { // AptPackage: Details of an APT package. For details about the apt // package manager, see https://wiki.debian.org/Apt. AptPackage *InventoryVersionedPackage `json:"aptPackage,omitempty"` // CosPackage: Details of a COS package. CosPackage *InventoryVersionedPackage `json:"cosPackage,omitempty"` // GoogetPackage: Details of a Googet package. For details about the // googet package manager, see https://github.com/google/googet. GoogetPackage *InventoryVersionedPackage `json:"googetPackage,omitempty"` // QfePackage: Details of a Windows Quick Fix engineering package. See // https://docs.microsoft.com/en-us/windows/win32/cimwin32prov/win32-quickfixengineering // for info in Windows Quick Fix Engineering. QfePackage *InventoryWindowsQuickFixEngineeringPackage `json:"qfePackage,omitempty"` // WuaPackage: Details of a Windows Update package. See // https://docs.microsoft.com/en-us/windows/win32/api/_wua/ for // information about Windows Update. WuaPackage *InventoryWindowsUpdatePackage `json:"wuaPackage,omitempty"` // YumPackage: Yum package info. For details about the yum package // manager, see // https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/deployment_guide/ch-yum. YumPackage *InventoryVersionedPackage `json:"yumPackage,omitempty"` // ZypperPackage: Details of a Zypper package. For details about the // Zypper package manager, see // https://en.opensuse.org/SDB:Zypper_manual. ZypperPackage *InventoryVersionedPackage `json:"zypperPackage,omitempty"` // ZypperPatch: Details of a Zypper patch. For details about the Zypper // package manager, see https://en.opensuse.org/SDB:Zypper_manual. ZypperPatch *InventoryZypperPatch `json:"zypperPatch,omitempty"` // ForceSendFields is a list of field names (e.g. "AptPackage") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "AptPackage") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InventorySoftwarePackage: Software package information of the operating system.
func (*InventorySoftwarePackage) MarshalJSON ¶
func (s *InventorySoftwarePackage) MarshalJSON() ([]byte, error)
type InventoryVersionedPackage ¶
type InventoryVersionedPackage struct { // Architecture: The system architecture this package is intended for. Architecture string `json:"architecture,omitempty"` // PackageName: The name of the package. PackageName string `json:"packageName,omitempty"` // Version: The version of the package. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "Architecture") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Architecture") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InventoryVersionedPackage: Information related to the a standard versioned package. This includes package info for APT, Yum, Zypper, and Googet package managers.
func (*InventoryVersionedPackage) MarshalJSON ¶
func (s *InventoryVersionedPackage) MarshalJSON() ([]byte, error)
type InventoryWindowsQuickFixEngineeringPackage ¶
type InventoryWindowsQuickFixEngineeringPackage struct { // Caption: A short textual description of the QFE update. Caption string `json:"caption,omitempty"` // Description: A textual description of the QFE update. Description string `json:"description,omitempty"` // HotFixId: Unique identifier associated with a particular QFE update. HotFixId string `json:"hotFixId,omitempty"` // InstallTime: Date that the QFE update was installed. Mapped from // installed_on field. InstallTime string `json:"installTime,omitempty"` // ForceSendFields is a list of field names (e.g. "Caption") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Caption") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InventoryWindowsQuickFixEngineeringPackage: Information related to a Quick Fix Engineering package. Fields are taken from Windows QuickFixEngineering Interface and match the source names: https://docs.microsoft.com/en-us/windows/win32/cimwin32prov/win32-quickfixengineering
func (*InventoryWindowsQuickFixEngineeringPackage) MarshalJSON ¶
func (s *InventoryWindowsQuickFixEngineeringPackage) MarshalJSON() ([]byte, error)
type InventoryWindowsUpdatePackage ¶
type InventoryWindowsUpdatePackage struct { // Categories: The categories that are associated with this update // package. Categories []*InventoryWindowsUpdatePackageWindowsUpdateCategory `json:"categories,omitempty"` // Description: The localized description of the update package. Description string `json:"description,omitempty"` // KbArticleIds: A collection of Microsoft Knowledge Base article IDs // that are associated with the update package. KbArticleIds []string `json:"kbArticleIds,omitempty"` // LastDeploymentChangeTime: The last published date of the update, in // (UTC) date and time. LastDeploymentChangeTime string `json:"lastDeploymentChangeTime,omitempty"` // MoreInfoUrls: A collection of URLs that provide more information // about the update package. MoreInfoUrls []string `json:"moreInfoUrls,omitempty"` // RevisionNumber: The revision number of this update package. RevisionNumber int64 `json:"revisionNumber,omitempty"` // SupportUrl: A hyperlink to the language-specific support information // for the update. SupportUrl string `json:"supportUrl,omitempty"` // Title: The localized title of the update package. Title string `json:"title,omitempty"` // UpdateId: Gets the identifier of an update package. Stays the same // across revisions. UpdateId string `json:"updateId,omitempty"` // ForceSendFields is a list of field names (e.g. "Categories") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Categories") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InventoryWindowsUpdatePackage: Details related to a Windows Update package. Field data and names are taken from Windows Update API IUpdate Interface: https://docs.microsoft.com/en-us/windows/win32/api/_wua/ Descriptive fields like title, and description are localized based on the locale of the VM being updated.
func (*InventoryWindowsUpdatePackage) MarshalJSON ¶
func (s *InventoryWindowsUpdatePackage) MarshalJSON() ([]byte, error)
type InventoryWindowsUpdatePackageWindowsUpdateCategory ¶
type InventoryWindowsUpdatePackageWindowsUpdateCategory struct { // Id: The identifier of the windows update category. Id string `json:"id,omitempty"` // Name: The name of the windows update category. Name string `json:"name,omitempty"` // ForceSendFields is a list of field names (e.g. "Id") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Id") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InventoryWindowsUpdatePackageWindowsUpdateCategory: Categories specified by the Windows Update.
func (*InventoryWindowsUpdatePackageWindowsUpdateCategory) MarshalJSON ¶
func (s *InventoryWindowsUpdatePackageWindowsUpdateCategory) MarshalJSON() ([]byte, error)
type InventoryZypperPatch ¶
type InventoryZypperPatch struct { // Category: The category of the patch. Category string `json:"category,omitempty"` // PatchName: The name of the patch. PatchName string `json:"patchName,omitempty"` // Severity: The severity specified for this patch Severity string `json:"severity,omitempty"` // Summary: Any summary information provided about this patch. Summary string `json:"summary,omitempty"` // ForceSendFields is a list of field names (e.g. "Category") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Category") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
InventoryZypperPatch: Details related to a Zypper Patch.
func (*InventoryZypperPatch) MarshalJSON ¶
func (s *InventoryZypperPatch) MarshalJSON() ([]byte, error)
type ListInstanceOSPoliciesCompliancesResponse ¶
type ListInstanceOSPoliciesCompliancesResponse struct { // InstanceOsPoliciesCompliances: List of instance OS policies // compliance objects. InstanceOsPoliciesCompliances []*InstanceOSPoliciesCompliance `json:"instanceOsPoliciesCompliances,omitempty"` // NextPageToken: The pagination token to retrieve the next page of // instance OS policies compliance objects. NextPageToken string `json:"nextPageToken,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. // "InstanceOsPoliciesCompliances") to unconditionally include in API // requests. By default, fields with empty values are omitted from API // requests. However, any non-pointer, non-interface field appearing in // ForceSendFields will be sent to the server regardless of whether the // field is empty or not. This may be used to include empty fields in // Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. // "InstanceOsPoliciesCompliances") to include in API requests with the // JSON null value. By default, fields with empty values are omitted // from API requests. However, any field with an empty value appearing // in NullFields will be sent to the server as null. It is an error if a // field in this list has a non-empty value. This may be used to include // null fields in Patch requests. NullFields []string `json:"-"` }
ListInstanceOSPoliciesCompliancesResponse: A response message for listing OS policies compliance data for all Compute Engine VMs in the given location.
func (*ListInstanceOSPoliciesCompliancesResponse) MarshalJSON ¶
func (s *ListInstanceOSPoliciesCompliancesResponse) MarshalJSON() ([]byte, error)
type ListInventoriesResponse ¶
type ListInventoriesResponse struct { // Inventories: List of inventory objects. Inventories []*Inventory `json:"inventories,omitempty"` // NextPageToken: The pagination token to retrieve the next page of // inventory objects. NextPageToken string `json:"nextPageToken,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Inventories") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Inventories") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
ListInventoriesResponse: A response message for listing inventory data for all VMs in a specified location.
func (*ListInventoriesResponse) MarshalJSON ¶
func (s *ListInventoriesResponse) MarshalJSON() ([]byte, error)
type ListOSPolicyAssignmentRevisionsResponse ¶
type ListOSPolicyAssignmentRevisionsResponse struct { // NextPageToken: The pagination token to retrieve the next page of OS // policy assignment revisions. NextPageToken string `json:"nextPageToken,omitempty"` // OsPolicyAssignments: The OS policy assignment revisions OsPolicyAssignments []*OSPolicyAssignment `json:"osPolicyAssignments,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "NextPageToken") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
ListOSPolicyAssignmentRevisionsResponse: A response message for listing all revisions for a OS policy assignment.
func (*ListOSPolicyAssignmentRevisionsResponse) MarshalJSON ¶
func (s *ListOSPolicyAssignmentRevisionsResponse) MarshalJSON() ([]byte, error)
type ListOSPolicyAssignmentsResponse ¶
type ListOSPolicyAssignmentsResponse struct { // NextPageToken: The pagination token to retrieve the next page of OS // policy assignments. NextPageToken string `json:"nextPageToken,omitempty"` // OsPolicyAssignments: The list of assignments OsPolicyAssignments []*OSPolicyAssignment `json:"osPolicyAssignments,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "NextPageToken") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
ListOSPolicyAssignmentsResponse: A response message for listing all assignments under given parent.
func (*ListOSPolicyAssignmentsResponse) MarshalJSON ¶
func (s *ListOSPolicyAssignmentsResponse) MarshalJSON() ([]byte, error)
type ListVulnerabilityReportsResponse ¶
type ListVulnerabilityReportsResponse struct { // NextPageToken: The pagination token to retrieve the next page of // vulnerabilityReports object. NextPageToken string `json:"nextPageToken,omitempty"` // VulnerabilityReports: List of vulnerabilityReport objects. VulnerabilityReports []*VulnerabilityReport `json:"vulnerabilityReports,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "NextPageToken") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
ListVulnerabilityReportsResponse: A response message for listing vulnerability reports for all VM instances in the specified location.
func (*ListVulnerabilityReportsResponse) MarshalJSON ¶
func (s *ListVulnerabilityReportsResponse) MarshalJSON() ([]byte, error)
type OSPolicy ¶
type OSPolicy struct { // AllowNoResourceGroupMatch: This flag determines the OS policy // compliance status when none of the resource groups within the policy // are applicable for a VM. Set this value to `true` if the policy needs // to be reported as compliant even if the policy has nothing to // validate or enforce. AllowNoResourceGroupMatch bool `json:"allowNoResourceGroupMatch,omitempty"` // Description: Policy description. Length of the description is limited // to 1024 characters. Description string `json:"description,omitempty"` // Id: Required. The id of the OS policy with the following // restrictions: * Must contain only lowercase letters, numbers, and // hyphens. * Must start with a letter. * Must be between 1-63 // characters. * Must end with a number or a letter. * Must be unique // within the assignment. Id string `json:"id,omitempty"` // Mode: Required. Policy mode // // Possible values: // "MODE_UNSPECIFIED" - Invalid mode // "VALIDATION" - This mode checks if the configuration resources in // the policy are in their desired state. No actions are performed if // they are not in the desired state. This mode is used for reporting // purposes. // "ENFORCEMENT" - This mode checks if the configuration resources in // the policy are in their desired state, and if not, enforces the // desired state. Mode string `json:"mode,omitempty"` // ResourceGroups: Required. List of resource groups for the policy. For // a particular VM, resource groups are evaluated in the order specified // and the first resource group that is applicable is selected and the // rest are ignored. If none of the resource groups are applicable for a // VM, the VM is considered to be non-compliant w.r.t this policy. This // behavior can be toggled by the flag `allow_no_resource_group_match` ResourceGroups []*OSPolicyResourceGroup `json:"resourceGroups,omitempty"` // ForceSendFields is a list of field names (e.g. // "AllowNoResourceGroupMatch") to unconditionally include in API // requests. By default, fields with empty values are omitted from API // requests. However, any non-pointer, non-interface field appearing in // ForceSendFields will be sent to the server regardless of whether the // field is empty or not. This may be used to include empty fields in // Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. // "AllowNoResourceGroupMatch") to include in API requests with the JSON // null value. By default, fields with empty values are omitted from API // requests. However, any field with an empty value appearing in // NullFields will be sent to the server as null. It is an error if a // field in this list has a non-empty value. This may be used to include // null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicy: An OS policy defines the desired state configuration for a VM.
func (*OSPolicy) MarshalJSON ¶
type OSPolicyAssignment ¶
type OSPolicyAssignment struct { // Baseline: Output only. Indicates that this revision has been // successfully rolled out in this zone and new VMs will be assigned OS // policies from this revision. For a given OS policy assignment, there // is only one revision with a value of `true` for this field. Baseline bool `json:"baseline,omitempty"` // Deleted: Output only. Indicates that this revision deletes the OS // policy assignment. Deleted bool `json:"deleted,omitempty"` // Description: OS policy assignment description. Length of the // description is limited to 1024 characters. Description string `json:"description,omitempty"` // InstanceFilter: Required. Filter to select VMs. InstanceFilter *OSPolicyAssignmentInstanceFilter `json:"instanceFilter,omitempty"` // Name: Resource name. Format: // `projects/{project_number}/locations/{location}/osPolicyAssignments/{o // s_policy_assignment_id}` This field is ignored when you create an OS // policy assignment. Name string `json:"name,omitempty"` // OsPolicies: Required. List of OS policies to be applied to the VMs. OsPolicies []*OSPolicy `json:"osPolicies,omitempty"` // Reconciling: Output only. Indicates that reconciliation is in // progress for the revision. This value is `true` when the // `rollout_state` is one of: * IN_PROGRESS * CANCELLING Reconciling bool `json:"reconciling,omitempty"` // RevisionCreateTime: Output only. The timestamp that the revision was // created. RevisionCreateTime string `json:"revisionCreateTime,omitempty"` // RevisionId: Output only. The assignment revision ID A new revision is // committed whenever a rollout is triggered for a OS policy assignment RevisionId string `json:"revisionId,omitempty"` // Rollout: Required. Rollout to deploy the OS policy assignment. A // rollout is triggered in the following situations: 1) // OSPolicyAssignment is created. 2) OSPolicyAssignment is updated and // the update contains changes to one of the following fields: - // instance_filter - os_policies 3) OSPolicyAssignment is deleted. Rollout *OSPolicyAssignmentRollout `json:"rollout,omitempty"` // RolloutState: Output only. OS policy assignment rollout state // // Possible values: // "ROLLOUT_STATE_UNSPECIFIED" - Invalid value // "IN_PROGRESS" - The rollout is in progress. // "CANCELLING" - The rollout is being cancelled. // "CANCELLED" - The rollout is cancelled. // "SUCCEEDED" - The rollout has completed successfully. RolloutState string `json:"rolloutState,omitempty"` // Uid: Output only. Server generated unique id for the OS policy // assignment resource. Uid string `json:"uid,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Baseline") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Baseline") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyAssignment: OS policy assignment is an API resource that is used to apply a set of OS policies to a dynamically targeted group of Compute Engine VM instances. An OS policy is used to define the desired state configuration for a Compute Engine VM instance through a set of configuration resources that provide capabilities such as installing or removing software packages, or executing a script. For more information, see OS policy and OS policy assignment (https://cloud.google.com/compute/docs/os-configuration-management/working-with-os-policies).
func (*OSPolicyAssignment) MarshalJSON ¶
func (s *OSPolicyAssignment) MarshalJSON() ([]byte, error)
type OSPolicyAssignmentInstanceFilter ¶
type OSPolicyAssignmentInstanceFilter struct { // All: Target all VMs in the project. If true, no other criteria is // permitted. All bool `json:"all,omitempty"` // ExclusionLabels: List of label sets used for VM exclusion. If the // list has more than one label set, the VM is excluded if any of the // label sets are applicable for the VM. This filter is applied last in // the filtering chain and therefore a VM is guaranteed to be excluded // if it satisfies one of the below label sets. ExclusionLabels []*OSPolicyAssignmentLabelSet `json:"exclusionLabels,omitempty"` // InclusionLabels: List of label sets used for VM inclusion. If the // list has more than one `LabelSet`, the VM is included if any of the // label sets are applicable for the VM. InclusionLabels []*OSPolicyAssignmentLabelSet `json:"inclusionLabels,omitempty"` // OsShortNames: A VM is included if it's OS short name matches with any // of the values provided in this list. OsShortNames []string `json:"osShortNames,omitempty"` // ForceSendFields is a list of field names (e.g. "All") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "All") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyAssignmentInstanceFilter: Message to represent the filters to select VMs for an assignment
func (*OSPolicyAssignmentInstanceFilter) MarshalJSON ¶
func (s *OSPolicyAssignmentInstanceFilter) MarshalJSON() ([]byte, error)
type OSPolicyAssignmentLabelSet ¶
type OSPolicyAssignmentLabelSet struct { // Labels: Labels are identified by key/value pairs in this map. A VM // should contain all the key/value pairs specified in this map to be // selected. Labels map[string]string `json:"labels,omitempty"` // ForceSendFields is a list of field names (e.g. "Labels") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Labels") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyAssignmentLabelSet: Message representing label set. * A label is a key value pair set for a VM. * A LabelSet is a set of labels. * Labels within a LabelSet are ANDed. In other words, a LabelSet is applicable for a VM only if it matches all the labels in the LabelSet. * Example: A LabelSet with 2 labels: `env=prod` and `type=webserver` will only be applicable for those VMs with both labels present.
func (*OSPolicyAssignmentLabelSet) MarshalJSON ¶
func (s *OSPolicyAssignmentLabelSet) MarshalJSON() ([]byte, error)
type OSPolicyAssignmentOperationMetadata ¶
type OSPolicyAssignmentOperationMetadata struct { // ApiMethod: The OS policy assignment API method. // // Possible values: // "API_METHOD_UNSPECIFIED" - Invalid value // "CREATE" - Create OS policy assignment API method // "UPDATE" - Update OS policy assignment API method // "DELETE" - Delete OS policy assignment API method ApiMethod string `json:"apiMethod,omitempty"` // OsPolicyAssignment: Reference to the `OSPolicyAssignment` API // resource. Format: // `projects/{project_number}/locations/{location}/osPolicyAssignments/{o // s_policy_assignment_id@revision_id}` OsPolicyAssignment string `json:"osPolicyAssignment,omitempty"` // RolloutStartTime: Rollout start time RolloutStartTime string `json:"rolloutStartTime,omitempty"` // RolloutState: State of the rollout // // Possible values: // "ROLLOUT_STATE_UNSPECIFIED" - Invalid value // "IN_PROGRESS" - The rollout is in progress. // "CANCELLING" - The rollout is being cancelled. // "CANCELLED" - The rollout is cancelled. // "SUCCEEDED" - The rollout has completed successfully. RolloutState string `json:"rolloutState,omitempty"` // RolloutUpdateTime: Rollout update time RolloutUpdateTime string `json:"rolloutUpdateTime,omitempty"` // ForceSendFields is a list of field names (e.g. "ApiMethod") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "ApiMethod") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyAssignmentOperationMetadata: OS policy assignment operation metadata provided by OS policy assignment API methods that return long running operations.
func (*OSPolicyAssignmentOperationMetadata) MarshalJSON ¶
func (s *OSPolicyAssignmentOperationMetadata) MarshalJSON() ([]byte, error)
type OSPolicyAssignmentRollout ¶
type OSPolicyAssignmentRollout struct { // DisruptionBudget: Required. The maximum number (or percentage) of VMs // per zone to disrupt at any given moment. DisruptionBudget *FixedOrPercent `json:"disruptionBudget,omitempty"` // MinWaitDuration: Required. This determines the minimum duration of // time to wait after the configuration changes are applied through the // current rollout. A VM continues to count towards the // `disruption_budget` at least until this duration of time has passed // after configuration changes are applied. MinWaitDuration string `json:"minWaitDuration,omitempty"` // ForceSendFields is a list of field names (e.g. "DisruptionBudget") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "DisruptionBudget") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` }
OSPolicyAssignmentRollout: Message to configure the rollout at the zonal level for the OS policy assignment.
func (*OSPolicyAssignmentRollout) MarshalJSON ¶
func (s *OSPolicyAssignmentRollout) MarshalJSON() ([]byte, error)
type OSPolicyOSFilter ¶
type OSPolicyOSFilter struct { // OsShortName: This should match OS short name emitted by the OS // inventory agent. An empty value matches any OS. OsShortName string `json:"osShortName,omitempty"` // OsVersion: This value should match the version emitted by the OS // inventory agent. Prefix matches are supported if asterisk(*) is // provided as the last character. For example, to match all versions // with a major version of `7`, specify the following value for this // field `7.*` OsVersion string `json:"osVersion,omitempty"` // ForceSendFields is a list of field names (e.g. "OsShortName") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "OsShortName") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyOSFilter: The `OSFilter` is used to specify the OS filtering criteria for the resource group.
func (*OSPolicyOSFilter) MarshalJSON ¶
func (s *OSPolicyOSFilter) MarshalJSON() ([]byte, error)
type OSPolicyResource ¶
type OSPolicyResource struct { // Exec: Exec resource Exec *OSPolicyResourceExecResource `json:"exec,omitempty"` // File: File resource File *OSPolicyResourceFileResource `json:"file,omitempty"` // Id: Required. The id of the resource with the following restrictions: // * Must contain only lowercase letters, numbers, and hyphens. * Must // start with a letter. * Must be between 1-63 characters. * Must end // with a number or a letter. * Must be unique within the OS policy. Id string `json:"id,omitempty"` // Pkg: Package resource Pkg *OSPolicyResourcePackageResource `json:"pkg,omitempty"` // Repository: Package repository resource Repository *OSPolicyResourceRepositoryResource `json:"repository,omitempty"` // ForceSendFields is a list of field names (e.g. "Exec") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Exec") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResource: An OS policy resource is used to define the desired state configuration and provides a specific functionality like installing/removing packages, executing a script etc. The system ensures that resources are always in their desired state by taking necessary actions if they have drifted from their desired state.
func (*OSPolicyResource) MarshalJSON ¶
func (s *OSPolicyResource) MarshalJSON() ([]byte, error)
type OSPolicyResourceCompliance ¶
type OSPolicyResourceCompliance struct { // ConfigSteps: Ordered list of configuration steps taken by the agent // for the OS policy resource. ConfigSteps []*OSPolicyResourceConfigStep `json:"configSteps,omitempty"` // ExecResourceOutput: ExecResource specific output. ExecResourceOutput *OSPolicyResourceComplianceExecResourceOutput `json:"execResourceOutput,omitempty"` // OsPolicyResourceId: The id of the OS policy resource. OsPolicyResourceId string `json:"osPolicyResourceId,omitempty"` // State: Compliance state of the OS policy resource. // // Possible values: // "OS_POLICY_COMPLIANCE_STATE_UNSPECIFIED" - Default value. This // value is unused. // "COMPLIANT" - Compliant state. // "NON_COMPLIANT" - Non-compliant state // "UNKNOWN" - Unknown compliance state. // "NO_OS_POLICIES_APPLICABLE" - No applicable OS policies were found // for the instance. This state is only applicable to the instance. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "ConfigSteps") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "ConfigSteps") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceCompliance: Compliance data for an OS policy resource.
func (*OSPolicyResourceCompliance) MarshalJSON ¶
func (s *OSPolicyResourceCompliance) MarshalJSON() ([]byte, error)
type OSPolicyResourceComplianceExecResourceOutput ¶
type OSPolicyResourceComplianceExecResourceOutput struct { // EnforcementOutput: Output from Enforcement phase output file (if // run). Output size is limited to 100K bytes. EnforcementOutput string `json:"enforcementOutput,omitempty"` // ForceSendFields is a list of field names (e.g. "EnforcementOutput") // to unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "EnforcementOutput") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` }
OSPolicyResourceComplianceExecResourceOutput: ExecResource specific output.
func (*OSPolicyResourceComplianceExecResourceOutput) MarshalJSON ¶
func (s *OSPolicyResourceComplianceExecResourceOutput) MarshalJSON() ([]byte, error)
type OSPolicyResourceConfigStep ¶
type OSPolicyResourceConfigStep struct { // ErrorMessage: An error message recorded during the execution of this // step. Only populated when outcome is FAILED. ErrorMessage string `json:"errorMessage,omitempty"` // Outcome: Outcome of the configuration step. // // Possible values: // "OUTCOME_UNSPECIFIED" - Default value. This value is unused. // "SUCCEEDED" - The step succeeded. // "FAILED" - The step failed. Outcome string `json:"outcome,omitempty"` // Type: Configuration step type. // // Possible values: // "TYPE_UNSPECIFIED" - Default value. This value is unused. // "VALIDATION" - Validation to detect resource conflicts, schema // errors, etc. // "DESIRED_STATE_CHECK" - Check the current desired state status of // the resource. // "DESIRED_STATE_ENFORCEMENT" - Enforce the desired state for a // resource that is not in desired state. // "DESIRED_STATE_CHECK_POST_ENFORCEMENT" - Re-check desired state // status for a resource after enforcement of all resources in the // current configuration run. This step is used to determine the final // desired state status for the resource. It accounts for any resources // that might have drifted from their desired state due to side effects // from configuring other resources during the current configuration // run. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "ErrorMessage") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "ErrorMessage") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceConfigStep: Step performed by the OS Config agent for configuring an `OSPolicyResource` to its desired state.
func (*OSPolicyResourceConfigStep) MarshalJSON ¶
func (s *OSPolicyResourceConfigStep) MarshalJSON() ([]byte, error)
type OSPolicyResourceExecResource ¶
type OSPolicyResourceExecResource struct { // Enforce: What to run to bring this resource into the desired state. // An exit code of 100 indicates "success", any other exit code // indicates a failure running enforce. Enforce *OSPolicyResourceExecResourceExec `json:"enforce,omitempty"` // Validate: Required. What to run to validate this resource is in the // desired state. An exit code of 100 indicates "in desired state", and // exit code of 101 indicates "not in desired state". Any other exit // code indicates a failure running validate. Validate *OSPolicyResourceExecResourceExec `json:"validate,omitempty"` // ForceSendFields is a list of field names (e.g. "Enforce") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Enforce") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceExecResource: A resource that allows executing scripts on the VM. The `ExecResource` has 2 stages: `validate` and `enforce` and both stages accept a script as an argument to execute. When the `ExecResource` is applied by the agent, it first executes the script in the `validate` stage. The `validate` stage can signal that the `ExecResource` is already in the desired state by returning an exit code of `100`. If the `ExecResource` is not in the desired state, it should return an exit code of `101`. Any other exit code returned by this stage is considered an error. If the `ExecResource` is not in the desired state based on the exit code from the `validate` stage, the agent proceeds to execute the script from the `enforce` stage. If the `ExecResource` is already in the desired state, the `enforce` stage will not be run. Similar to `validate` stage, the `enforce` stage should return an exit code of `100` to indicate that the resource in now in its desired state. Any other exit code is considered an error. NOTE: An exit code of `100` was chosen over `0` (and `101` vs `1`) to have an explicit indicator of `in desired state`, `not in desired state` and errors. Because, for example, Powershell will always return an exit code of `0` unless an `exit` statement is provided in the script. So, for reasons of consistency and being explicit, exit codes `100` and `101` were chosen.
func (*OSPolicyResourceExecResource) MarshalJSON ¶
func (s *OSPolicyResourceExecResource) MarshalJSON() ([]byte, error)
type OSPolicyResourceExecResourceExec ¶
type OSPolicyResourceExecResourceExec struct { // Args: Optional arguments to pass to the source during execution. Args []string `json:"args,omitempty"` // File: A remote or local file. File *OSPolicyResourceFile `json:"file,omitempty"` // Interpreter: Required. The script interpreter to use. // // Possible values: // "INTERPRETER_UNSPECIFIED" - Defaults to NONE. // "NONE" - If no interpreter is specified the source will be executed // directly, which will likely only succeed for executables and scripts // with shebang lines. [Wikipedia // shebang](https://en.wikipedia.org/wiki/Shebang_(Unix)). // "SHELL" - Indicates that the script will be run with /bin/sh on // Linux and cmd.exe on windows. // "POWERSHELL" - Indicates that the script will be run with // powershell. Interpreter string `json:"interpreter,omitempty"` // OutputFilePath: Only recorded for enforce Exec. Path to an output // file (that is created by this Exec) whose content will be recorded in // OSPolicyResourceCompliance after a successful run. Absence or failure // to read this file will result in this ExecResource being // non-compliant. Output file size is limited to 100K bytes. OutputFilePath string `json:"outputFilePath,omitempty"` // Script: An inline script. The size of the script is limited to 1024 // characters. Script string `json:"script,omitempty"` // ForceSendFields is a list of field names (e.g. "Args") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Args") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceExecResourceExec: A file or script to execute.
func (*OSPolicyResourceExecResourceExec) MarshalJSON ¶
func (s *OSPolicyResourceExecResourceExec) MarshalJSON() ([]byte, error)
type OSPolicyResourceFile ¶
type OSPolicyResourceFile struct { // AllowInsecure: Defaults to false. When false, files are subject to // validations based on the file type: Remote: A checksum must be // specified. Cloud Storage: An object generation number must be // specified. AllowInsecure bool `json:"allowInsecure,omitempty"` // Gcs: A Cloud Storage object. Gcs *OSPolicyResourceFileGcs `json:"gcs,omitempty"` // LocalPath: A local path within the VM to use. LocalPath string `json:"localPath,omitempty"` // Remote: A generic remote file. Remote *OSPolicyResourceFileRemote `json:"remote,omitempty"` // ForceSendFields is a list of field names (e.g. "AllowInsecure") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "AllowInsecure") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceFile: A remote or local file.
func (*OSPolicyResourceFile) MarshalJSON ¶
func (s *OSPolicyResourceFile) MarshalJSON() ([]byte, error)
type OSPolicyResourceFileGcs ¶
type OSPolicyResourceFileGcs struct { // Bucket: Required. Bucket of the Cloud Storage object. Bucket string `json:"bucket,omitempty"` // Generation: Generation number of the Cloud Storage object. Generation int64 `json:"generation,omitempty,string"` // Object: Required. Name of the Cloud Storage object. Object string `json:"object,omitempty"` // ForceSendFields is a list of field names (e.g. "Bucket") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Bucket") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceFileGcs: Specifies a file available as a Cloud Storage Object.
func (*OSPolicyResourceFileGcs) MarshalJSON ¶
func (s *OSPolicyResourceFileGcs) MarshalJSON() ([]byte, error)
type OSPolicyResourceFileRemote ¶
type OSPolicyResourceFileRemote struct { // Sha256Checksum: SHA256 checksum of the remote file. Sha256Checksum string `json:"sha256Checksum,omitempty"` // Uri: Required. URI from which to fetch the object. It should contain // both the protocol and path following the format // `{protocol}://{location}`. Uri string `json:"uri,omitempty"` // ForceSendFields is a list of field names (e.g. "Sha256Checksum") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Sha256Checksum") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the // server as null. It is an error if a field in this list has a // non-empty value. This may be used to include null fields in Patch // requests. NullFields []string `json:"-"` }
OSPolicyResourceFileRemote: Specifies a file available via some URI.
func (*OSPolicyResourceFileRemote) MarshalJSON ¶
func (s *OSPolicyResourceFileRemote) MarshalJSON() ([]byte, error)
type OSPolicyResourceFileResource ¶
type OSPolicyResourceFileResource struct { // Content: A a file with this content. The size of the content is // limited to 1024 characters. Content string `json:"content,omitempty"` // File: A remote or local source. File *OSPolicyResourceFile `json:"file,omitempty"` // Path: Required. The absolute path of the file within the VM. Path string `json:"path,omitempty"` // Permissions: Consists of three octal digits which represent, in // order, the permissions of the owner, group, and other users for the // file (similarly to the numeric mode used in the linux chmod utility). // Each digit represents a three bit number with the 4 bit corresponding // to the read permissions, the 2 bit corresponds to the write bit, and // the one bit corresponds to the execute permission. Default behavior // is 755. Below are some examples of permissions and their associated // values: read, write, and execute: 7 read and execute: 5 read and // write: 6 read only: 4 Permissions string `json:"permissions,omitempty"` // State: Required. Desired state of the file. // // Possible values: // "DESIRED_STATE_UNSPECIFIED" - Unspecified is invalid. // "PRESENT" - Ensure file at path is present. // "ABSENT" - Ensure file at path is absent. // "CONTENTS_MATCH" - Ensure the contents of the file at path matches. // If the file does not exist it will be created. State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Content") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Content") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceFileResource: A resource that manages the state of a file.
func (*OSPolicyResourceFileResource) MarshalJSON ¶
func (s *OSPolicyResourceFileResource) MarshalJSON() ([]byte, error)
type OSPolicyResourceGroup ¶
type OSPolicyResourceGroup struct { // OsFilter: Used to specify the OS filter for a resource group OsFilter *OSPolicyOSFilter `json:"osFilter,omitempty"` // Resources: Required. List of resources configured for this resource // group. The resources are executed in the exact order specified here. Resources []*OSPolicyResource `json:"resources,omitempty"` // ForceSendFields is a list of field names (e.g. "OsFilter") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "OsFilter") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceGroup: Resource groups provide a mechanism to group OS policy resources. Resource groups enable OS policy authors to create a single OS policy to be applied to VMs running different operating Systems. When the OS policy is applied to a target VM, the appropriate resource group within the OS policy is selected based on the `OSFilter` specified within the resource group.
func (*OSPolicyResourceGroup) MarshalJSON ¶
func (s *OSPolicyResourceGroup) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResource ¶
type OSPolicyResourcePackageResource struct { // Apt: A package managed by Apt. Apt *OSPolicyResourcePackageResourceAPT `json:"apt,omitempty"` // Deb: A deb package file. Deb *OSPolicyResourcePackageResourceDeb `json:"deb,omitempty"` // DesiredState: Required. The desired state the agent should maintain // for this package. // // Possible values: // "DESIRED_STATE_UNSPECIFIED" - Unspecified is invalid. // "INSTALLED" - Ensure that the package is installed. // "REMOVED" - The agent ensures that the package is not installed and // uninstalls it if detected. DesiredState string `json:"desiredState,omitempty"` // Googet: A package managed by GooGet. Googet *OSPolicyResourcePackageResourceGooGet `json:"googet,omitempty"` // Msi: An MSI package. Msi *OSPolicyResourcePackageResourceMSI `json:"msi,omitempty"` // Rpm: An rpm package file. Rpm *OSPolicyResourcePackageResourceRPM `json:"rpm,omitempty"` // Yum: A package managed by YUM. Yum *OSPolicyResourcePackageResourceYUM `json:"yum,omitempty"` // Zypper: A package managed by Zypper. Zypper *OSPolicyResourcePackageResourceZypper `json:"zypper,omitempty"` // ForceSendFields is a list of field names (e.g. "Apt") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Apt") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResource: A resource that manages a system package.
func (*OSPolicyResourcePackageResource) MarshalJSON ¶
func (s *OSPolicyResourcePackageResource) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResourceAPT ¶
type OSPolicyResourcePackageResourceAPT struct { // Name: Required. Package name. Name string `json:"name,omitempty"` // ForceSendFields is a list of field names (e.g. "Name") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Name") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResourceAPT: A package managed by APT. - install: `apt-get update && apt-get -y install [name]` - remove: `apt-get -y remove [name]`
func (*OSPolicyResourcePackageResourceAPT) MarshalJSON ¶
func (s *OSPolicyResourcePackageResourceAPT) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResourceDeb ¶
type OSPolicyResourcePackageResourceDeb struct { // PullDeps: Whether dependencies should also be installed. - install // when false: `dpkg -i package` - install when true: `apt-get update && // apt-get -y install package.deb` PullDeps bool `json:"pullDeps,omitempty"` // Source: Required. A deb package. Source *OSPolicyResourceFile `json:"source,omitempty"` // ForceSendFields is a list of field names (e.g. "PullDeps") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "PullDeps") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResourceDeb: A deb package file. dpkg packages only support INSTALLED state.
func (*OSPolicyResourcePackageResourceDeb) MarshalJSON ¶
func (s *OSPolicyResourcePackageResourceDeb) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResourceGooGet ¶
type OSPolicyResourcePackageResourceGooGet struct { // Name: Required. Package name. Name string `json:"name,omitempty"` // ForceSendFields is a list of field names (e.g. "Name") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Name") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResourceGooGet: A package managed by GooGet. - install: `googet -noconfirm install package` - remove: `googet -noconfirm remove package`
func (*OSPolicyResourcePackageResourceGooGet) MarshalJSON ¶
func (s *OSPolicyResourcePackageResourceGooGet) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResourceMSI ¶
type OSPolicyResourcePackageResourceMSI struct { // Properties: Additional properties to use during installation. This // should be in the format of Property=Setting. Appended to the defaults // of `ACTION=INSTALL REBOOT=ReallySuppress`. Properties []string `json:"properties,omitempty"` // Source: Required. The MSI package. Source *OSPolicyResourceFile `json:"source,omitempty"` // ForceSendFields is a list of field names (e.g. "Properties") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Properties") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResourceMSI: An MSI package. MSI packages only support INSTALLED state.
func (*OSPolicyResourcePackageResourceMSI) MarshalJSON ¶
func (s *OSPolicyResourcePackageResourceMSI) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResourceRPM ¶
type OSPolicyResourcePackageResourceRPM struct { // PullDeps: Whether dependencies should also be installed. - install // when false: `rpm --upgrade --replacepkgs package.rpm` - install when // true: `yum -y install package.rpm` or `zypper -y install package.rpm` PullDeps bool `json:"pullDeps,omitempty"` // Source: Required. An rpm package. Source *OSPolicyResourceFile `json:"source,omitempty"` // ForceSendFields is a list of field names (e.g. "PullDeps") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "PullDeps") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResourceRPM: An RPM package file. RPM packages only support INSTALLED state.
func (*OSPolicyResourcePackageResourceRPM) MarshalJSON ¶
func (s *OSPolicyResourcePackageResourceRPM) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResourceYUM ¶
type OSPolicyResourcePackageResourceYUM struct { // Name: Required. Package name. Name string `json:"name,omitempty"` // ForceSendFields is a list of field names (e.g. "Name") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Name") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResourceYUM: A package managed by YUM. - install: `yum -y install package` - remove: `yum -y remove package`
func (*OSPolicyResourcePackageResourceYUM) MarshalJSON ¶
func (s *OSPolicyResourcePackageResourceYUM) MarshalJSON() ([]byte, error)
type OSPolicyResourcePackageResourceZypper ¶
type OSPolicyResourcePackageResourceZypper struct { // Name: Required. Package name. Name string `json:"name,omitempty"` // ForceSendFields is a list of field names (e.g. "Name") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Name") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourcePackageResourceZypper: A package managed by Zypper. - install: `zypper -y install package` - remove: `zypper -y rm package`
func (*OSPolicyResourcePackageResourceZypper) MarshalJSON ¶
func (s *OSPolicyResourcePackageResourceZypper) MarshalJSON() ([]byte, error)
type OSPolicyResourceRepositoryResource ¶
type OSPolicyResourceRepositoryResource struct { // Apt: An Apt Repository. Apt *OSPolicyResourceRepositoryResourceAptRepository `json:"apt,omitempty"` // Goo: A Goo Repository. Goo *OSPolicyResourceRepositoryResourceGooRepository `json:"goo,omitempty"` // Yum: A Yum Repository. Yum *OSPolicyResourceRepositoryResourceYumRepository `json:"yum,omitempty"` // Zypper: A Zypper Repository. Zypper *OSPolicyResourceRepositoryResourceZypperRepository `json:"zypper,omitempty"` // ForceSendFields is a list of field names (e.g. "Apt") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Apt") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceRepositoryResource: A resource that manages a package repository.
func (*OSPolicyResourceRepositoryResource) MarshalJSON ¶
func (s *OSPolicyResourceRepositoryResource) MarshalJSON() ([]byte, error)
type OSPolicyResourceRepositoryResourceAptRepository ¶
type OSPolicyResourceRepositoryResourceAptRepository struct { // ArchiveType: Required. Type of archive files in this repository. // // Possible values: // "ARCHIVE_TYPE_UNSPECIFIED" - Unspecified is invalid. // "DEB" - Deb indicates that the archive contains binary files. // "DEB_SRC" - Deb-src indicates that the archive contains source // files. ArchiveType string `json:"archiveType,omitempty"` // Components: Required. List of components for this repository. Must // contain at least one item. Components []string `json:"components,omitempty"` // Distribution: Required. Distribution of this repository. Distribution string `json:"distribution,omitempty"` // GpgKey: URI of the key file for this repository. The agent maintains // a keyring at `/etc/apt/trusted.gpg.d/osconfig_agent_managed.gpg`. GpgKey string `json:"gpgKey,omitempty"` // Uri: Required. URI for this repository. Uri string `json:"uri,omitempty"` // ForceSendFields is a list of field names (e.g. "ArchiveType") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "ArchiveType") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceRepositoryResourceAptRepository: Represents a single apt package repository. These will be added to a repo file that will be managed at `/etc/apt/sources.list.d/google_osconfig.list`.
func (*OSPolicyResourceRepositoryResourceAptRepository) MarshalJSON ¶
func (s *OSPolicyResourceRepositoryResourceAptRepository) MarshalJSON() ([]byte, error)
type OSPolicyResourceRepositoryResourceGooRepository ¶
type OSPolicyResourceRepositoryResourceGooRepository struct { // Name: Required. The name of the repository. Name string `json:"name,omitempty"` // Url: Required. The url of the repository. Url string `json:"url,omitempty"` // ForceSendFields is a list of field names (e.g. "Name") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Name") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceRepositoryResourceGooRepository: Represents a Goo package repository. These are added to a repo file that is managed at `C:/ProgramData/GooGet/repos/google_osconfig.repo`.
func (*OSPolicyResourceRepositoryResourceGooRepository) MarshalJSON ¶
func (s *OSPolicyResourceRepositoryResourceGooRepository) MarshalJSON() ([]byte, error)
type OSPolicyResourceRepositoryResourceYumRepository ¶
type OSPolicyResourceRepositoryResourceYumRepository struct { // BaseUrl: Required. The location of the repository directory. BaseUrl string `json:"baseUrl,omitempty"` // DisplayName: The display name of the repository. DisplayName string `json:"displayName,omitempty"` // GpgKeys: URIs of GPG keys. GpgKeys []string `json:"gpgKeys,omitempty"` // Id: Required. A one word, unique name for this repository. This is // the `repo id` in the yum config file and also the `display_name` if // `display_name` is omitted. This id is also used as the unique // identifier when checking for resource conflicts. Id string `json:"id,omitempty"` // ForceSendFields is a list of field names (e.g. "BaseUrl") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "BaseUrl") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceRepositoryResourceYumRepository: Represents a single yum package repository. These are added to a repo file that is managed at `/etc/yum.repos.d/google_osconfig.repo`.
func (*OSPolicyResourceRepositoryResourceYumRepository) MarshalJSON ¶
func (s *OSPolicyResourceRepositoryResourceYumRepository) MarshalJSON() ([]byte, error)
type OSPolicyResourceRepositoryResourceZypperRepository ¶
type OSPolicyResourceRepositoryResourceZypperRepository struct { // BaseUrl: Required. The location of the repository directory. BaseUrl string `json:"baseUrl,omitempty"` // DisplayName: The display name of the repository. DisplayName string `json:"displayName,omitempty"` // GpgKeys: URIs of GPG keys. GpgKeys []string `json:"gpgKeys,omitempty"` // Id: Required. A one word, unique name for this repository. This is // the `repo id` in the zypper config file and also the `display_name` // if `display_name` is omitted. This id is also used as the unique // identifier when checking for GuestPolicy conflicts. Id string `json:"id,omitempty"` // ForceSendFields is a list of field names (e.g. "BaseUrl") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "BaseUrl") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
OSPolicyResourceRepositoryResourceZypperRepository: Represents a single zypper package repository. These are added to a repo file that is managed at `/etc/zypp/repos.d/google_osconfig.repo`.
func (*OSPolicyResourceRepositoryResourceZypperRepository) MarshalJSON ¶
func (s *OSPolicyResourceRepositoryResourceZypperRepository) MarshalJSON() ([]byte, error)
type Operation ¶
type Operation struct { // Done: If the value is `false`, it means the operation is still in // progress. If `true`, the operation is completed, and either `error` // or `response` is available. Done bool `json:"done,omitempty"` // Error: The error result of the operation in case of failure or // cancellation. Error *Status `json:"error,omitempty"` // Metadata: Service-specific metadata associated with the operation. It // typically contains progress information and common metadata such as // create time. Some services might not provide such metadata. Any // method that returns a long-running operation should document the // metadata type, if any. Metadata googleapi.RawMessage `json:"metadata,omitempty"` // Name: The server-assigned name, which is only unique within the same // service that originally returns it. If you use the default HTTP // mapping, the `name` should be a resource name ending with // `operations/{unique_id}`. Name string `json:"name,omitempty"` // Response: The normal response of the operation in case of success. If // the original method returns no data on success, such as `Delete`, the // response is `google.protobuf.Empty`. If the original method is // standard `Get`/`Create`/`Update`, the response should be the // resource. For other methods, the response should have the type // `XxxResponse`, where `Xxx` is the original method name. For example, // if the original method name is `TakeSnapshot()`, the inferred // response type is `TakeSnapshotResponse`. Response googleapi.RawMessage `json:"response,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Done") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Done") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
Operation: This resource represents a long-running operation that is the result of a network API call.
func (*Operation) MarshalJSON ¶
type ProjectsLocationsInstanceOSPoliciesCompliancesGetCall ¶
type ProjectsLocationsInstanceOSPoliciesCompliancesGetCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Context ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Context(ctx context.Context) *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Do ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Do(opts ...googleapi.CallOption) (*InstanceOSPoliciesCompliance, error)
Do executes the "osconfig.projects.locations.instanceOSPoliciesCompliances.get" call. Exactly one of *InstanceOSPoliciesCompliance or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *InstanceOSPoliciesCompliance.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Fields ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Header ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
type ProjectsLocationsInstanceOSPoliciesCompliancesListCall ¶
type ProjectsLocationsInstanceOSPoliciesCompliancesListCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Context ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Context(ctx context.Context) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Do ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Do(opts ...googleapi.CallOption) (*ListInstanceOSPoliciesCompliancesResponse, error)
Do executes the "osconfig.projects.locations.instanceOSPoliciesCompliances.list" call. Exactly one of *ListInstanceOSPoliciesCompliancesResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListInstanceOSPoliciesCompliancesResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Fields ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Filter ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Filter(filter string) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
Filter sets the optional parameter "filter": If provided, this field specifies the criteria that must be met by a `InstanceOSPoliciesCompliance` API resource to be included in the response.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Header ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) PageSize ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) PageSize(pageSize int64) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
PageSize sets the optional parameter "pageSize": The maximum number of results to return.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) PageToken ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) PageToken(pageToken string) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
PageToken sets the optional parameter "pageToken": A pagination token returned from a previous call to `ListInstanceOSPoliciesCompliances` that indicates where this listing should continue from.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Pages ¶
func (c *ProjectsLocationsInstanceOSPoliciesCompliancesListCall) Pages(ctx context.Context, f func(*ListInstanceOSPoliciesCompliancesResponse) error) error
Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.
type ProjectsLocationsInstanceOSPoliciesCompliancesService ¶
type ProjectsLocationsInstanceOSPoliciesCompliancesService struct {
// contains filtered or unexported fields
}
func NewProjectsLocationsInstanceOSPoliciesCompliancesService ¶
func NewProjectsLocationsInstanceOSPoliciesCompliancesService(s *Service) *ProjectsLocationsInstanceOSPoliciesCompliancesService
func (*ProjectsLocationsInstanceOSPoliciesCompliancesService) Get ¶
func (r *ProjectsLocationsInstanceOSPoliciesCompliancesService) Get(name string) *ProjectsLocationsInstanceOSPoliciesCompliancesGetCall
Get: Get OS policies compliance data for the specified Compute Engine VM instance.
- name: API resource name for instance OS policies compliance resource. Format: `projects/{project}/locations/{location}/instanceOSPoliciesComplianc es/{instance}` For `{project}`, either Compute Engine project-number or project-id can be provided. For `{instance}`, either Compute Engine VM instance-id or instance-name can be provided.
func (*ProjectsLocationsInstanceOSPoliciesCompliancesService) List ¶
func (r *ProjectsLocationsInstanceOSPoliciesCompliancesService) List(parent string) *ProjectsLocationsInstanceOSPoliciesCompliancesListCall
List: List OS policies compliance data for all Compute Engine VM instances in the specified zone.
- parent: The parent resource name. Format: `projects/{project}/locations/{location}` For `{project}`, either Compute Engine project-number or project-id can be provided.
type ProjectsLocationsInstancesInventoriesGetCall ¶
type ProjectsLocationsInstancesInventoriesGetCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesInventoriesGetCall) Context ¶
func (c *ProjectsLocationsInstancesInventoriesGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesInventoriesGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesInventoriesGetCall) Do ¶
func (c *ProjectsLocationsInstancesInventoriesGetCall) Do(opts ...googleapi.CallOption) (*Inventory, error)
Do executes the "osconfig.projects.locations.instances.inventories.get" call. Exactly one of *Inventory or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Inventory.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesInventoriesGetCall) Fields ¶
func (c *ProjectsLocationsInstancesInventoriesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesInventoriesGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesInventoriesGetCall) Header ¶
func (c *ProjectsLocationsInstancesInventoriesGetCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstancesInventoriesGetCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstancesInventoriesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesInventoriesGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ProjectsLocationsInstancesInventoriesGetCall) View ¶
func (c *ProjectsLocationsInstancesInventoriesGetCall) View(view string) *ProjectsLocationsInstancesInventoriesGetCall
View sets the optional parameter "view": Inventory view indicating what information should be included in the inventory resource. If unspecified, the default view is BASIC.
Possible values:
"INVENTORY_VIEW_UNSPECIFIED" - The default value. The API defaults
to the BASIC view.
"BASIC" - Returns the basic inventory information that includes
`os_info`.
"FULL" - Returns all fields.
type ProjectsLocationsInstancesInventoriesListCall ¶
type ProjectsLocationsInstancesInventoriesListCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesInventoriesListCall) Context ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesInventoriesListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesInventoriesListCall) Do ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) Do(opts ...googleapi.CallOption) (*ListInventoriesResponse, error)
Do executes the "osconfig.projects.locations.instances.inventories.list" call. Exactly one of *ListInventoriesResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListInventoriesResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesInventoriesListCall) Fields ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesInventoriesListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesInventoriesListCall) Filter ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) Filter(filter string) *ProjectsLocationsInstancesInventoriesListCall
Filter sets the optional parameter "filter": If provided, this field specifies the criteria that must be met by a `Inventory` API resource to be included in the response.
func (*ProjectsLocationsInstancesInventoriesListCall) Header ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstancesInventoriesListCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesInventoriesListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ProjectsLocationsInstancesInventoriesListCall) PageSize ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesInventoriesListCall
PageSize sets the optional parameter "pageSize": The maximum number of results to return.
func (*ProjectsLocationsInstancesInventoriesListCall) PageToken ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesInventoriesListCall
PageToken sets the optional parameter "pageToken": A pagination token returned from a previous call to `ListInventories` that indicates where this listing should continue from.
func (*ProjectsLocationsInstancesInventoriesListCall) Pages ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) Pages(ctx context.Context, f func(*ListInventoriesResponse) error) error
Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.
func (*ProjectsLocationsInstancesInventoriesListCall) View ¶
func (c *ProjectsLocationsInstancesInventoriesListCall) View(view string) *ProjectsLocationsInstancesInventoriesListCall
View sets the optional parameter "view": Inventory view indicating what information should be included in the inventory resource. If unspecified, the default view is BASIC.
Possible values:
"INVENTORY_VIEW_UNSPECIFIED" - The default value. The API defaults
to the BASIC view.
"BASIC" - Returns the basic inventory information that includes
`os_info`.
"FULL" - Returns all fields.
type ProjectsLocationsInstancesInventoriesService ¶
type ProjectsLocationsInstancesInventoriesService struct {
// contains filtered or unexported fields
}
func NewProjectsLocationsInstancesInventoriesService ¶
func NewProjectsLocationsInstancesInventoriesService(s *Service) *ProjectsLocationsInstancesInventoriesService
func (*ProjectsLocationsInstancesInventoriesService) Get ¶
func (r *ProjectsLocationsInstancesInventoriesService) Get(name string) *ProjectsLocationsInstancesInventoriesGetCall
Get: Get inventory data for the specified VM instance. If the VM has no associated inventory, the message `NOT_FOUND` is returned.
- name: API resource name for inventory resource. Format: `projects/{project}/locations/{location}/instances/{instance}/invent ory` For `{project}`, either `project-number` or `project-id` can be provided. For `{instance}`, either Compute Engine `instance-id` or `instance-name` can be provided.
func (*ProjectsLocationsInstancesInventoriesService) List ¶
func (r *ProjectsLocationsInstancesInventoriesService) List(parent string) *ProjectsLocationsInstancesInventoriesListCall
List: List inventory data for all VM instances in the specified zone.
- parent: The parent resource name. Format: `projects/{project}/locations/{location}/instances/{instance}` For `{project}`, either `project-number` or `project-id` can be provided. For `{instance}`, only hyphen or dash character is supported to list inventories across VMs.
type ProjectsLocationsInstancesService ¶
type ProjectsLocationsInstancesService struct { Inventories *ProjectsLocationsInstancesInventoriesService VulnerabilityReports *ProjectsLocationsInstancesVulnerabilityReportsService // contains filtered or unexported fields }
func NewProjectsLocationsInstancesService ¶
func NewProjectsLocationsInstancesService(s *Service) *ProjectsLocationsInstancesService
type ProjectsLocationsInstancesVulnerabilityReportsGetCall ¶
type ProjectsLocationsInstancesVulnerabilityReportsGetCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesVulnerabilityReportsGetCall) Context ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesVulnerabilityReportsGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesVulnerabilityReportsGetCall) Do ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Do(opts ...googleapi.CallOption) (*VulnerabilityReport, error)
Do executes the "osconfig.projects.locations.instances.vulnerabilityReports.get" call. Exactly one of *VulnerabilityReport or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *VulnerabilityReport.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesVulnerabilityReportsGetCall) Fields ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesVulnerabilityReportsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesVulnerabilityReportsGetCall) Header ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstancesVulnerabilityReportsGetCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesVulnerabilityReportsGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
type ProjectsLocationsInstancesVulnerabilityReportsListCall ¶
type ProjectsLocationsInstancesVulnerabilityReportsListCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) Context ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Context(ctx context.Context) *ProjectsLocationsInstancesVulnerabilityReportsListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) Do ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Do(opts ...googleapi.CallOption) (*ListVulnerabilityReportsResponse, error)
Do executes the "osconfig.projects.locations.instances.vulnerabilityReports.list" call. Exactly one of *ListVulnerabilityReportsResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListVulnerabilityReportsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) Fields ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesVulnerabilityReportsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) Filter ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Filter(filter string) *ProjectsLocationsInstancesVulnerabilityReportsListCall
Filter sets the optional parameter "filter": If provided, this field specifies the criteria that must be met by a `vulnerabilityReport` API resource to be included in the response.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) Header ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesVulnerabilityReportsListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) PageSize ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesVulnerabilityReportsListCall
PageSize sets the optional parameter "pageSize": The maximum number of results to return.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) PageToken ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) PageToken(pageToken string) *ProjectsLocationsInstancesVulnerabilityReportsListCall
PageToken sets the optional parameter "pageToken": A pagination token returned from a previous call to `ListVulnerabilityReports` that indicates where this listing should continue from.
func (*ProjectsLocationsInstancesVulnerabilityReportsListCall) Pages ¶
func (c *ProjectsLocationsInstancesVulnerabilityReportsListCall) Pages(ctx context.Context, f func(*ListVulnerabilityReportsResponse) error) error
Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.
type ProjectsLocationsInstancesVulnerabilityReportsService ¶
type ProjectsLocationsInstancesVulnerabilityReportsService struct {
// contains filtered or unexported fields
}
func NewProjectsLocationsInstancesVulnerabilityReportsService ¶
func NewProjectsLocationsInstancesVulnerabilityReportsService(s *Service) *ProjectsLocationsInstancesVulnerabilityReportsService
func (*ProjectsLocationsInstancesVulnerabilityReportsService) Get ¶
func (r *ProjectsLocationsInstancesVulnerabilityReportsService) Get(name string) *ProjectsLocationsInstancesVulnerabilityReportsGetCall
Get: Gets the vulnerability report for the specified VM instance. Only VMs with inventory data have vulnerability reports associated with them.
- name: API resource name for vulnerability resource. Format: `projects/{project}/locations/{location}/instances/{instance}/vulner abilityReport` For `{project}`, either `project-number` or `project-id` can be provided. For `{instance}`, either Compute Engine `instance-id` or `instance-name` can be provided.
func (*ProjectsLocationsInstancesVulnerabilityReportsService) List ¶
func (r *ProjectsLocationsInstancesVulnerabilityReportsService) List(parent string) *ProjectsLocationsInstancesVulnerabilityReportsListCall
List: List vulnerability reports for all VM instances in the specified zone.
- parent: The parent resource name. Format: `projects/{project}/locations/{location}/instances/{instance}` For `{project}`, either `project-number` or `project-id` can be provided. For `{instance}`, only `-` character is supported to list vulnerability reports across VMs.
type ProjectsLocationsOsPolicyAssignmentsCreateCall ¶
type ProjectsLocationsOsPolicyAssignmentsCreateCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsCreateCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsCreateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsCreateCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.create" call. Exactly one of *Operation or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsCreateCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsCreateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsCreateCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsOsPolicyAssignmentsCreateCall) OsPolicyAssignmentId ¶
func (c *ProjectsLocationsOsPolicyAssignmentsCreateCall) OsPolicyAssignmentId(osPolicyAssignmentId string) *ProjectsLocationsOsPolicyAssignmentsCreateCall
OsPolicyAssignmentId sets the optional parameter "osPolicyAssignmentId": Required. The logical name of the OS policy assignment in the project with the following restrictions: * Must contain only lowercase letters, numbers, and hyphens. * Must start with a letter. * Must be between 1-63 characters. * Must end with a number or a letter. * Must be unique within the project.
type ProjectsLocationsOsPolicyAssignmentsDeleteCall ¶
type ProjectsLocationsOsPolicyAssignmentsDeleteCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsDeleteCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsDeleteCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsDeleteCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.delete" call. Exactly one of *Operation or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsDeleteCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsDeleteCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsDeleteCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
type ProjectsLocationsOsPolicyAssignmentsGetCall ¶
type ProjectsLocationsOsPolicyAssignmentsGetCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsGetCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsGetCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Do(opts ...googleapi.CallOption) (*OSPolicyAssignment, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.get" call. Exactly one of *OSPolicyAssignment or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *OSPolicyAssignment.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsGetCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsGetCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsOsPolicyAssignmentsGetCall) IfNoneMatch ¶
func (c *ProjectsLocationsOsPolicyAssignmentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
type ProjectsLocationsOsPolicyAssignmentsListCall ¶
type ProjectsLocationsOsPolicyAssignmentsListCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsListCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsListCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Do(opts ...googleapi.CallOption) (*ListOSPolicyAssignmentsResponse, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.list" call. Exactly one of *ListOSPolicyAssignmentsResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListOSPolicyAssignmentsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsListCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsListCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsOsPolicyAssignmentsListCall) IfNoneMatch ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ProjectsLocationsOsPolicyAssignmentsListCall) PageSize ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) PageSize(pageSize int64) *ProjectsLocationsOsPolicyAssignmentsListCall
PageSize sets the optional parameter "pageSize": The maximum number of assignments to return.
func (*ProjectsLocationsOsPolicyAssignmentsListCall) PageToken ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) PageToken(pageToken string) *ProjectsLocationsOsPolicyAssignmentsListCall
PageToken sets the optional parameter "pageToken": A pagination token returned from a previous call to `ListOSPolicyAssignments` that indicates where this listing should continue from.
func (*ProjectsLocationsOsPolicyAssignmentsListCall) Pages ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListCall) Pages(ctx context.Context, f func(*ListOSPolicyAssignmentsResponse) error) error
Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.
type ProjectsLocationsOsPolicyAssignmentsListRevisionsCall ¶
type ProjectsLocationsOsPolicyAssignmentsListRevisionsCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Do(opts ...googleapi.CallOption) (*ListOSPolicyAssignmentRevisionsResponse, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.listRevisions" call. Exactly one of *ListOSPolicyAssignmentRevisionsResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListOSPolicyAssignmentRevisionsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) IfNoneMatch ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) PageSize ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) PageSize(pageSize int64) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
PageSize sets the optional parameter "pageSize": The maximum number of revisions to return.
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) PageToken ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) PageToken(pageToken string) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
PageToken sets the optional parameter "pageToken": A pagination token returned from a previous call to `ListOSPolicyAssignmentRevisions` that indicates where this listing should continue from.
func (*ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Pages ¶
func (c *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall) Pages(ctx context.Context, f func(*ListOSPolicyAssignmentRevisionsResponse) error) error
Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.
type ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall ¶
type ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.operations.cancel" call. Exactly one of *Empty or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Empty.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
type ProjectsLocationsOsPolicyAssignmentsOperationsGetCall ¶
type ProjectsLocationsOsPolicyAssignmentsOperationsGetCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.operations.get" call. Exactly one of *Operation or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) IfNoneMatch ¶
func (c *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
type ProjectsLocationsOsPolicyAssignmentsOperationsService ¶
type ProjectsLocationsOsPolicyAssignmentsOperationsService struct {
// contains filtered or unexported fields
}
func NewProjectsLocationsOsPolicyAssignmentsOperationsService ¶
func NewProjectsLocationsOsPolicyAssignmentsOperationsService(s *Service) *ProjectsLocationsOsPolicyAssignmentsOperationsService
func (*ProjectsLocationsOsPolicyAssignmentsOperationsService) Cancel ¶
func (r *ProjectsLocationsOsPolicyAssignmentsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOsPolicyAssignmentsOperationsCancelCall
Cancel: Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.
- name: The name of the operation resource to be cancelled.
func (*ProjectsLocationsOsPolicyAssignmentsOperationsService) Get ¶
func (r *ProjectsLocationsOsPolicyAssignmentsOperationsService) Get(name string) *ProjectsLocationsOsPolicyAssignmentsOperationsGetCall
Get: Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.
- name: The name of the operation resource.
type ProjectsLocationsOsPolicyAssignmentsPatchCall ¶
type ProjectsLocationsOsPolicyAssignmentsPatchCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsOsPolicyAssignmentsPatchCall) Context ¶
func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Context(ctx context.Context) *ProjectsLocationsOsPolicyAssignmentsPatchCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsOsPolicyAssignmentsPatchCall) Do ¶
func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error)
Do executes the "osconfig.projects.locations.osPolicyAssignments.patch" call. Exactly one of *Operation or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsOsPolicyAssignmentsPatchCall) Fields ¶
func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsOsPolicyAssignmentsPatchCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsOsPolicyAssignmentsPatchCall) Header ¶
func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsOsPolicyAssignmentsPatchCall) UpdateMask ¶
func (c *ProjectsLocationsOsPolicyAssignmentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsOsPolicyAssignmentsPatchCall
UpdateMask sets the optional parameter "updateMask": Field mask that controls which fields of the assignment should be updated.
type ProjectsLocationsOsPolicyAssignmentsService ¶
type ProjectsLocationsOsPolicyAssignmentsService struct { Operations *ProjectsLocationsOsPolicyAssignmentsOperationsService // contains filtered or unexported fields }
func NewProjectsLocationsOsPolicyAssignmentsService ¶
func NewProjectsLocationsOsPolicyAssignmentsService(s *Service) *ProjectsLocationsOsPolicyAssignmentsService
func (*ProjectsLocationsOsPolicyAssignmentsService) Create ¶
func (r *ProjectsLocationsOsPolicyAssignmentsService) Create(parent string, ospolicyassignment *OSPolicyAssignment) *ProjectsLocationsOsPolicyAssignmentsCreateCall
Create: Create an OS policy assignment. This method also creates the first revision of the OS policy assignment. This method returns a long running operation (LRO) that contains the rollout details. The rollout can be cancelled by cancelling the LRO. For more information, see Method: projects.locations.osPolicyAssignments.operations.cancel (https://cloud.google.com/compute/docs/osconfig/rest/v1alpha/projects.locations.osPolicyAssignments.operations/cancel).
- parent: The parent resource name in the form: projects/{project}/locations/{location}.
func (*ProjectsLocationsOsPolicyAssignmentsService) Delete ¶
func (r *ProjectsLocationsOsPolicyAssignmentsService) Delete(name string) *ProjectsLocationsOsPolicyAssignmentsDeleteCall
Delete: Delete the OS policy assignment. This method creates a new revision of the OS policy assignment. This method returns a long running operation (LRO) that contains the rollout details. The rollout can be cancelled by cancelling the LRO. If the LRO completes and is not cancelled, all revisions associated with the OS policy assignment are deleted. For more information, see Method: projects.locations.osPolicyAssignments.operations.cancel (https://cloud.google.com/compute/docs/osconfig/rest/v1alpha/projects.locations.osPolicyAssignments.operations/cancel).
- name: The name of the OS policy assignment to be deleted.
func (*ProjectsLocationsOsPolicyAssignmentsService) Get ¶
func (r *ProjectsLocationsOsPolicyAssignmentsService) Get(name string) *ProjectsLocationsOsPolicyAssignmentsGetCall
Get: Retrieve an existing OS policy assignment. This method always returns the latest revision. In order to retrieve a previous revision of the assignment, also provide the revision ID in the `name` parameter.
- name: The resource name of OS policy assignment. Format: `projects/{project}/locations/{location}/osPolicyAssignments/{os_pol icy_assignment}@{revisionId}`.
func (*ProjectsLocationsOsPolicyAssignmentsService) List ¶
func (r *ProjectsLocationsOsPolicyAssignmentsService) List(parent string) *ProjectsLocationsOsPolicyAssignmentsListCall
List: List the OS policy assignments under the parent resource. For each OS policy assignment, the latest revision is returned.
- parent: The parent resource name.
func (*ProjectsLocationsOsPolicyAssignmentsService) ListRevisions ¶
func (r *ProjectsLocationsOsPolicyAssignmentsService) ListRevisions(name string) *ProjectsLocationsOsPolicyAssignmentsListRevisionsCall
ListRevisions: List the OS policy assignment revisions for a given OS policy assignment.
- name: The name of the OS policy assignment to list revisions for.
func (*ProjectsLocationsOsPolicyAssignmentsService) Patch ¶
func (r *ProjectsLocationsOsPolicyAssignmentsService) Patch(name string, ospolicyassignment *OSPolicyAssignment) *ProjectsLocationsOsPolicyAssignmentsPatchCall
Patch: Update an existing OS policy assignment. This method creates a new revision of the OS policy assignment. This method returns a long running operation (LRO) that contains the rollout details. The rollout can be cancelled by cancelling the LRO. For more information, see Method: projects.locations.osPolicyAssignments.operations.cancel (https://cloud.google.com/compute/docs/osconfig/rest/v1alpha/projects.locations.osPolicyAssignments.operations/cancel).
- name: Resource name. Format: `projects/{project_number}/locations/{location}/osPolicyAssignments/ {os_policy_assignment_id}` This field is ignored when you create an OS policy assignment.
type ProjectsLocationsService ¶
type ProjectsLocationsService struct { InstanceOSPoliciesCompliances *ProjectsLocationsInstanceOSPoliciesCompliancesService Instances *ProjectsLocationsInstancesService OsPolicyAssignments *ProjectsLocationsOsPolicyAssignmentsService // contains filtered or unexported fields }
func NewProjectsLocationsService ¶
func NewProjectsLocationsService(s *Service) *ProjectsLocationsService
type ProjectsService ¶
type ProjectsService struct { Locations *ProjectsLocationsService // contains filtered or unexported fields }
func NewProjectsService ¶
func NewProjectsService(s *Service) *ProjectsService
type Service ¶
type Service struct { BasePath string // API endpoint base URL UserAgent string // optional additional User-Agent fragment Projects *ProjectsService // contains filtered or unexported fields }
func New
deprecated
New creates a new Service. It uses the provided http.Client for requests.
Deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
func NewService ¶
NewService creates a new Service.
type Status ¶
type Status struct { // Code: The status code, which should be an enum value of // google.rpc.Code. Code int64 `json:"code,omitempty"` // Details: A list of messages that carry the error details. There is a // common set of message types for APIs to use. Details []googleapi.RawMessage `json:"details,omitempty"` // Message: A developer-facing error message, which should be in // English. Any user-facing error message should be localized and sent // in the google.rpc.Status.details field, or localized by the client. Message string `json:"message,omitempty"` // ForceSendFields is a list of field names (e.g. "Code") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Code") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
Status: The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the API Design Guide (https://cloud.google.com/apis/design/errors).
func (*Status) MarshalJSON ¶
type VulnerabilityReport ¶
type VulnerabilityReport struct { // Name: Output only. The `vulnerabilityReport` API resource name. // Format: // `projects/{project_number}/locations/{location}/instances/{instance_id // }/vulnerabilityReport` Name string `json:"name,omitempty"` // UpdateTime: Output only. The timestamp for when the last // vulnerability report was generated for the VM. UpdateTime string `json:"updateTime,omitempty"` // Vulnerabilities: Output only. List of vulnerabilities affecting the // VM. Vulnerabilities []*VulnerabilityReportVulnerability `json:"vulnerabilities,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Name") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Name") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
VulnerabilityReport: This API resource represents the vulnerability report for a specified Compute Engine virtual machine (VM) instance at a given point in time. For more information, see Vulnerability reports (https://cloud.google.com/compute/docs/instances/os-inventory-management#vulnerability-reports).
func (*VulnerabilityReport) MarshalJSON ¶
func (s *VulnerabilityReport) MarshalJSON() ([]byte, error)
type VulnerabilityReportVulnerability ¶
type VulnerabilityReportVulnerability struct { // AvailableInventoryItemIds: Corresponds to the `AVAILABLE_PACKAGE` // inventory item on the VM. If the vulnerability report was not updated // after the VM inventory update, these values might not display in VM // inventory. If there is no available fix, the field is empty. The // `inventory_item` value specifies the latest `SoftwarePackage` // available to the VM that fixes the vulnerability. AvailableInventoryItemIds []string `json:"availableInventoryItemIds,omitempty"` // CreateTime: The timestamp for when the vulnerability was first // detected. CreateTime string `json:"createTime,omitempty"` // Details: Contains metadata as per the upstream feed of the operating // system and NVD. Details *VulnerabilityReportVulnerabilityDetails `json:"details,omitempty"` // InstalledInventoryItemIds: Corresponds to the `INSTALLED_PACKAGE` // inventory item on the VM. This field displays the inventory items // affected by this vulnerability. If the vulnerability report was not // updated after the VM inventory update, these values might not display // in VM inventory. For some distros, this field may be empty. InstalledInventoryItemIds []string `json:"installedInventoryItemIds,omitempty"` // UpdateTime: The timestamp for when the vulnerability was last // modified. UpdateTime string `json:"updateTime,omitempty"` // ForceSendFields is a list of field names (e.g. // "AvailableInventoryItemIds") to unconditionally include in API // requests. By default, fields with empty values are omitted from API // requests. However, any non-pointer, non-interface field appearing in // ForceSendFields will be sent to the server regardless of whether the // field is empty or not. This may be used to include empty fields in // Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. // "AvailableInventoryItemIds") to include in API requests with the JSON // null value. By default, fields with empty values are omitted from API // requests. However, any field with an empty value appearing in // NullFields will be sent to the server as null. It is an error if a // field in this list has a non-empty value. This may be used to include // null fields in Patch requests. NullFields []string `json:"-"` }
VulnerabilityReportVulnerability: A vulnerability affecting the VM instance.
func (*VulnerabilityReportVulnerability) MarshalJSON ¶
func (s *VulnerabilityReportVulnerability) MarshalJSON() ([]byte, error)
type VulnerabilityReportVulnerabilityDetails ¶
type VulnerabilityReportVulnerabilityDetails struct { // Cve: The CVE of the vulnerability. CVE cannot be empty and the // combination of should be unique across vulnerabilities for a VM. Cve string `json:"cve,omitempty"` // CvssV2Score: The CVSS V2 score of this vulnerability. CVSS V2 score // is on a scale of 0 - 10 where 0 indicates low severity and 10 // indicates high severity. CvssV2Score float64 `json:"cvssV2Score,omitempty"` // CvssV3: The full description of the CVSSv3 for this vulnerability // from NVD. CvssV3 *CVSSv3 `json:"cvssV3,omitempty"` // Description: The note or description describing the vulnerability // from the distro. Description string `json:"description,omitempty"` // References: Corresponds to the references attached to the // `VulnerabilityDetails`. References []*VulnerabilityReportVulnerabilityDetailsReference `json:"references,omitempty"` // Severity: Assigned severity/impact ranking from the distro. Severity string `json:"severity,omitempty"` // ForceSendFields is a list of field names (e.g. "Cve") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Cve") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
VulnerabilityReportVulnerabilityDetails: Contains metadata information for the vulnerability. This information is collected from the upstream feed of the operating system.
func (*VulnerabilityReportVulnerabilityDetails) MarshalJSON ¶
func (s *VulnerabilityReportVulnerabilityDetails) MarshalJSON() ([]byte, error)
func (*VulnerabilityReportVulnerabilityDetails) UnmarshalJSON ¶
func (s *VulnerabilityReportVulnerabilityDetails) UnmarshalJSON(data []byte) error
type VulnerabilityReportVulnerabilityDetailsReference ¶
type VulnerabilityReportVulnerabilityDetailsReference struct { // Url: The url of the reference. Url string `json:"url,omitempty"` // ForceSendFields is a list of field names (e.g. "Url") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Url") to include in API // requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
VulnerabilityReportVulnerabilityDetailsReference: A reference for this vulnerability.
func (*VulnerabilityReportVulnerabilityDetailsReference) MarshalJSON ¶
func (s *VulnerabilityReportVulnerabilityDetailsReference) MarshalJSON() ([]byte, error)