{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--aws-m2-environment.json",
  "title": "AWSM2EnvironmentProperties",
  "description": "Represents a runtime environment that can run migrated mainframe applications.. Source:- No source definition found, add manually please",
  "x-lintel": {
    "source": "https://raw.githubusercontent.com/lalcebo/json-schema/master/serverless/resources/cloudformation-modified/aws-m2-environment.json",
    "sourceSha256": "690e2fecb10468631ffd2276a73847b5ea51aa8ebd82afb3e56989cf1f68263c"
  },
  "type": "object",
  "properties": {
    "Description": {
      "oneOf": [
        {
          "type": "string",
          "maxLength": 500,
          "minLength": 0
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "The description of the environment."
    },
    "EngineType": {
      "$ref": "#/$defs/EngineType"
    },
    "EngineVersion": {
      "oneOf": [
        {
          "type": "string",
          "pattern": "^\\S{1,10}$"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "The version of the runtime engine for the environment."
    },
    "HighAvailabilityConfig": {
      "$ref": "#/$defs/HighAvailabilityConfig"
    },
    "InstanceType": {
      "oneOf": [
        {
          "type": "string",
          "pattern": "^\\S{1,20}$"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "The type of instance underlying the environment."
    },
    "KmsKeyId": {
      "oneOf": [
        {
          "type": "string",
          "maxLength": 2048
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "The ID or the Amazon Resource Name (ARN) of the customer managed KMS Key used for encrypting environment-related resources."
    },
    "Name": {
      "oneOf": [
        {
          "type": "string",
          "pattern": "^[A-Za-z0-9][A-Za-z0-9_\\-]{1,59}$"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "The name of the environment."
    },
    "PreferredMaintenanceWindow": {
      "oneOf": [
        {
          "type": "string",
          "pattern": "^\\S{1,50}$"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Configures a desired maintenance window for the environment. If you do not provide a value, a random system-generated value will be assigned."
    },
    "PubliclyAccessible": {
      "type": "boolean",
      "description": "Specifies whether the environment is publicly accessible."
    },
    "SecurityGroupIds": {
      "type": "array",
      "description": "The list of security groups for the VPC associated with this environment.",
      "insertionOrder": false,
      "items": {
        "type": "string",
        "pattern": "^\\S{1,50}$"
      }
    },
    "StorageConfigurations": {
      "type": "array",
      "description": "The storage configurations defined for the runtime environment.",
      "insertionOrder": false,
      "items": {
        "$ref": "#/$defs/StorageConfiguration"
      }
    },
    "SubnetIds": {
      "type": "array",
      "description": "The unique identifiers of the subnets assigned to this runtime environment.",
      "insertionOrder": false,
      "items": {
        "type": "string",
        "pattern": "^\\S{1,50}$"
      }
    },
    "Tags": {
      "description": "Tags associated to this environment.",
      "$ref": "#/$defs/TagMap"
    }
  },
  "typeName": "AWS::M2::Environment",
  "$defs": {
    "EfsStorageConfiguration": {
      "type": "object",
      "description": "Defines the storage configuration for an Amazon EFS file system.",
      "properties": {
        "FileSystemId": {
          "oneOf": [
            {
              "type": "string",
              "pattern": "^\\S{1,200}$"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "The file system identifier."
        },
        "MountPoint": {
          "oneOf": [
            {
              "type": "string",
              "pattern": "^\\S{1,200}$"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "The mount point for the file system."
        }
      },
      "required": [
        "FileSystemId",
        "MountPoint"
      ],
      "title": "AWSM2EnvironmentEfsStorageConfigurationDefinition",
      "additionalProperties": false
    },
    "EngineType": {
      "oneOf": [
        {
          "type": "string",
          "enum": [
            "microfocus",
            "bluage"
          ]
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "The target platform for the environment.",
      "title": "AWSM2EnvironmentEngineTypeDefinition"
    },
    "FsxStorageConfiguration": {
      "type": "object",
      "description": "Defines the storage configuration for an Amazon FSx file system.",
      "properties": {
        "FileSystemId": {
          "oneOf": [
            {
              "type": "string",
              "pattern": "^\\S{1,200}$"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "The file system identifier."
        },
        "MountPoint": {
          "oneOf": [
            {
              "type": "string",
              "pattern": "^\\S{1,200}$"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "The mount point for the file system."
        }
      },
      "required": [
        "FileSystemId",
        "MountPoint"
      ],
      "title": "AWSM2EnvironmentFsxStorageConfigurationDefinition",
      "additionalProperties": false
    },
    "HighAvailabilityConfig": {
      "type": "object",
      "description": "Defines the details of a high availability configuration.",
      "properties": {
        "DesiredCapacity": {
          "type": "integer",
          "maximum": 100,
          "minimum": 1
        }
      },
      "required": [
        "DesiredCapacity"
      ],
      "title": "AWSM2EnvironmentHighAvailabilityConfigDefinition",
      "additionalProperties": false
    },
    "StorageConfiguration": {
      "type": "object",
      "description": "Defines the storage configuration for an environment.",
      "oneOf": [
        {
          "properties": {
            "Efs": {
              "$ref": "#/$defs/EfsStorageConfiguration"
            }
          },
          "required": [
            "Efs"
          ],
          "additionalProperties": false,
          "type": "object"
        },
        {
          "properties": {
            "Fsx": {
              "$ref": "#/$defs/FsxStorageConfiguration"
            }
          },
          "required": [
            "Fsx"
          ],
          "additionalProperties": false,
          "type": "object"
        }
      ],
      "title": "AWSM2EnvironmentStorageConfigurationDefinition"
    },
    "TagMap": {
      "type": "object",
      "description": "Defines tags associated to an environment.",
      "maxProperties": 200,
      "minProperties": 0,
      "additionalProperties": false,
      "title": "AWSM2EnvironmentTagMapDefinition",
      "patternProperties": {
        "^(?!aws:).+$": {
          "type": "string",
          "maxLength": 256,
          "minLength": 0
        }
      }
    }
  },
  "additionalProperties": false,
  "primaryIdentifier": [
    "/properties/EnvironmentArn"
  ],
  "tagging": {
    "taggable": true,
    "tagOnCreate": true,
    "tagUpdatable": true,
    "cloudFormationSystemTags": false
  },
  "required": [
    "EngineType",
    "InstanceType",
    "Name"
  ],
  "readOnlyProperties": [
    "/properties/EnvironmentArn",
    "/properties/EnvironmentId"
  ],
  "createOnlyProperties": [
    "/properties/Description",
    "/properties/EngineType",
    "/properties/KmsKeyId",
    "/properties/Name",
    "/properties/PubliclyAccessible",
    "/properties/SecurityGroupIds",
    "/properties/StorageConfigurations",
    "/properties/SubnetIds"
  ]
}
