UNPKG

@pulumi/azure-compliance-policies

Version:

This repository contains a growing set of Compliance Policies to validate your infrastructure using Pulumi's Crossguard Policy-as-Code framework.

489 lines (488 loc) 27.5 kB
"use strict"; // Copyright 2016-2024, Pulumi Corporation. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // // ------------------------------- WARNING ------------------------------------- // This file was programmatically generated. Do not edit unless you know what // you're doing. // ------------------------------- WARNING ------------------------------------- Object.defineProperty(exports, "__esModule", { value: true }); exports.OnlineEndpoint = exports.OnlineDeployment = exports.ModelVersion = exports.ModelContainer = exports.LabelingJob = exports.Job = exports.EnvironmentSpecificationVersion = exports.EnvironmentContainer = exports.Datastore = exports.DataVersion = exports.DataContainer = exports.CodeVersion = exports.CodeContainer = exports.BatchEndpoint = exports.BatchDeployment = void 0; const policy_1 = require("@pulumi/policy"); const compliance_policy_manager_1 = require("@pulumi/compliance-policy-manager"); const v20210301preview_1 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_2 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_3 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_4 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_5 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_6 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_7 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_8 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_9 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_10 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_11 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_12 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_13 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_14 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); const v20210301preview_15 = require("@pulumi/azure-native/machinelearningservices/v20210301preview"); var BatchDeployment; (function (BatchDeployment) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.BatchDeployment). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ BatchDeployment.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-batchdeployment-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.BatchDeployment).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_1.BatchDeployment, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure BatchDeployment shouldn't use an unstable API (machinelearningservices.v20210301preview.BatchDeployment). A compatible replacement can be found at 'machinelearningservices.BatchDeployment'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(BatchDeployment || (BatchDeployment = {})); exports.BatchDeployment = BatchDeployment; var BatchEndpoint; (function (BatchEndpoint) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.BatchEndpoint). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ BatchEndpoint.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-batchendpoint-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.BatchEndpoint).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_2.BatchEndpoint, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure BatchEndpoint shouldn't use an unstable API (machinelearningservices.v20210301preview.BatchEndpoint). A compatible replacement can be found at 'machinelearningservices.BatchEndpoint'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(BatchEndpoint || (BatchEndpoint = {})); exports.BatchEndpoint = BatchEndpoint; var CodeContainer; (function (CodeContainer) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.CodeContainer). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ CodeContainer.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-codecontainer-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.CodeContainer).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_3.CodeContainer, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure CodeContainer shouldn't use an unstable API (machinelearningservices.v20210301preview.CodeContainer). A compatible replacement can be found at 'machinelearningservices.CodeContainer'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(CodeContainer || (CodeContainer = {})); exports.CodeContainer = CodeContainer; var CodeVersion; (function (CodeVersion) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.CodeVersion). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ CodeVersion.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-codeversion-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.CodeVersion).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_4.CodeVersion, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure CodeVersion shouldn't use an unstable API (machinelearningservices.v20210301preview.CodeVersion). A compatible replacement can be found at 'machinelearningservices.CodeVersion'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(CodeVersion || (CodeVersion = {})); exports.CodeVersion = CodeVersion; var DataContainer; (function (DataContainer) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.DataContainer). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ DataContainer.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-datacontainer-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.DataContainer).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_5.DataContainer, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure DataContainer shouldn't use an unstable API (machinelearningservices.v20210301preview.DataContainer). A compatible replacement can be found at 'machinelearningservices.DataContainer'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(DataContainer || (DataContainer = {})); exports.DataContainer = DataContainer; var DataVersion; (function (DataVersion) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.DataVersion). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ DataVersion.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-dataversion-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.DataVersion).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_6.DataVersion, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure DataVersion shouldn't use an unstable API (machinelearningservices.v20210301preview.DataVersion). A compatible replacement can be found at 'machinelearningservices.DataVersion'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(DataVersion || (DataVersion = {})); exports.DataVersion = DataVersion; var Datastore; (function (Datastore) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.Datastore). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ Datastore.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-datastore-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.Datastore).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_7.Datastore, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure Datastore shouldn't use an unstable API (machinelearningservices.v20210301preview.Datastore). A compatible replacement can be found at 'machinelearningservices.Datastore'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(Datastore || (Datastore = {})); exports.Datastore = Datastore; var EnvironmentContainer; (function (EnvironmentContainer) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.EnvironmentContainer). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ EnvironmentContainer.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-environmentcontainer-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.EnvironmentContainer).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_8.EnvironmentContainer, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure EnvironmentContainer shouldn't use an unstable API (machinelearningservices.v20210301preview.EnvironmentContainer). A compatible replacement can be found at 'machinelearningservices.EnvironmentContainer'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(EnvironmentContainer || (EnvironmentContainer = {})); exports.EnvironmentContainer = EnvironmentContainer; var EnvironmentSpecificationVersion; (function (EnvironmentSpecificationVersion) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.EnvironmentSpecificationVersion). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ EnvironmentSpecificationVersion.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-environmentspecificationversion-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.EnvironmentSpecificationVersion).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_9.EnvironmentSpecificationVersion, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure EnvironmentSpecificationVersion shouldn't use an unstable API (machinelearningservices.v20210301preview.EnvironmentSpecificationVersion). A compatible replacement can be found at 'machinelearningservices.EnvironmentSpecificationVersion'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(EnvironmentSpecificationVersion || (EnvironmentSpecificationVersion = {})); exports.EnvironmentSpecificationVersion = EnvironmentSpecificationVersion; var Job; (function (Job) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.Job). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ Job.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-job-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.Job).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_10.Job, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure Job shouldn't use an unstable API (machinelearningservices.v20210301preview.Job). A compatible replacement can be found at 'machinelearningservices.Job'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(Job || (Job = {})); exports.Job = Job; var LabelingJob; (function (LabelingJob) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.LabelingJob). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ LabelingJob.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-labelingjob-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.LabelingJob).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_11.LabelingJob, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure LabelingJob shouldn't use an unstable API (machinelearningservices.v20210301preview.LabelingJob). A compatible replacement can be found at 'machinelearningservices.LabelingJob'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(LabelingJob || (LabelingJob = {})); exports.LabelingJob = LabelingJob; var ModelContainer; (function (ModelContainer) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.ModelContainer). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ ModelContainer.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-modelcontainer-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.ModelContainer).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_12.ModelContainer, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure ModelContainer shouldn't use an unstable API (machinelearningservices.v20210301preview.ModelContainer). A compatible replacement can be found at 'machinelearningservices.ModelContainer'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(ModelContainer || (ModelContainer = {})); exports.ModelContainer = ModelContainer; var ModelVersion; (function (ModelVersion) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.ModelVersion). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ ModelVersion.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-modelversion-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.ModelVersion).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_13.ModelVersion, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure ModelVersion shouldn't use an unstable API (machinelearningservices.v20210301preview.ModelVersion). A compatible replacement can be found at 'machinelearningservices.ModelVersion'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(ModelVersion || (ModelVersion = {})); exports.ModelVersion = ModelVersion; var OnlineDeployment; (function (OnlineDeployment) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.OnlineDeployment). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ OnlineDeployment.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-onlinedeployment-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.OnlineDeployment).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_14.OnlineDeployment, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure OnlineDeployment shouldn't use an unstable API (machinelearningservices.v20210301preview.OnlineDeployment). A compatible replacement can be found at 'machinelearningservices.OnlineDeployment'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(OnlineDeployment || (OnlineDeployment = {})); exports.OnlineDeployment = OnlineDeployment; var OnlineEndpoint; (function (OnlineEndpoint) { /** * Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.OnlineEndpoint). * * @severity medium * @frameworks none * @topics api, preview, unstable * @link https://learn.microsoft.com/en-us/rest/api/azure/ */ OnlineEndpoint.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({ resourceValidationPolicy: { name: "azurenative-machinelearningservices-v20210301preview-onlineendpoint-disallow-preview-resource", description: "Disallow the use of non-stable (Preview) Azure resouces (machinelearningservices.v20210301preview.OnlineEndpoint).", configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema, enforcementLevel: "advisory", validateResource: (0, policy_1.validateResourceOfType)(v20210301preview_15.OnlineEndpoint, (_, args, reportViolation) => { if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) { return; } reportViolation("Azure OnlineEndpoint shouldn't use an unstable API (machinelearningservices.v20210301preview.OnlineEndpoint). A compatible replacement can be found at 'machinelearningservices.OnlineEndpoint'."); }), }, vendors: ["azure"], services: ["machinelearningservices"], severity: "medium", topics: ["api", "unstable", "preview"], }); })(OnlineEndpoint || (OnlineEndpoint = {})); exports.OnlineEndpoint = OnlineEndpoint;