public PersistentVolumeClaim Deploy() { var inputMap = new Pulumi.InputMap <string>(); inputMap.Add("type", "gp2"); inputMap.Add("fsType", "ext4"); var storageClass = new StorageClass("storage-sql-data", new StorageClassArgs { Metadata = new ObjectMetaArgs { Name = "storage-sql-data", Annotations = new Pulumi.InputMap <string> { { "storageclass.kubernetes.io/is-default-class", "true" } } }, Provisioner = "kubernetes.io/aws-ebs" }); var volumneClaim = new PersistentVolumeClaim("mssql-volumneclaim", new PersistentVolumeClaimArgs { Metadata = new ObjectMetaArgs { Name = "mssql-volume-claim" }, Spec = new PersistentVolumeClaimSpecArgs { StorageClassName = "storage-sql-data", AccessModes = "ReadWriteOnce", Resources = new ResourceRequirementsArgs { Requests = new Pulumi.InputMap <string> { { "storage", "7Gi" } } } }, }); return(volumneClaim); }
/// <summary> /// Validate the object. /// </summary> /// <exception cref="ValidationException"> /// Thrown if validation fails /// </exception> public virtual void Validate() { if (Name == null) { throw new ValidationException(ValidationRules.CannotBeNull, "Name"); } if (AwsElasticBlockStore != null) { AwsElasticBlockStore.Validate(); } if (AzureDisk != null) { AzureDisk.Validate(); } if (AzureFile != null) { AzureFile.Validate(); } if (Cephfs != null) { Cephfs.Validate(); } if (Cinder != null) { Cinder.Validate(); } if (FlexVolume != null) { FlexVolume.Validate(); } if (GcePersistentDisk != null) { GcePersistentDisk.Validate(); } if (GitRepo != null) { GitRepo.Validate(); } if (Glusterfs != null) { Glusterfs.Validate(); } if (HostPath != null) { HostPath.Validate(); } if (Iscsi != null) { Iscsi.Validate(); } if (Nfs != null) { Nfs.Validate(); } if (PersistentVolumeClaim != null) { PersistentVolumeClaim.Validate(); } if (PhotonPersistentDisk != null) { PhotonPersistentDisk.Validate(); } if (PortworxVolume != null) { PortworxVolume.Validate(); } if (Projected != null) { Projected.Validate(); } if (Quobyte != null) { Quobyte.Validate(); } if (Rbd != null) { Rbd.Validate(); } if (ScaleIO != null) { ScaleIO.Validate(); } if (VsphereVolume != null) { VsphereVolume.Validate(); } }