All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.virtualmachineimages.inputs.ImageTemplatePropertiesValidateArgs Maven / Gradle / Ivy

// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azurenative.virtualmachineimages.inputs;

import com.pulumi.azurenative.virtualmachineimages.inputs.ImageTemplateFileValidatorArgs;
import com.pulumi.azurenative.virtualmachineimages.inputs.ImageTemplatePowerShellValidatorArgs;
import com.pulumi.azurenative.virtualmachineimages.inputs.ImageTemplateShellValidatorArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.core.internal.Codegen;
import java.lang.Boolean;
import java.lang.Object;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * Configuration options and list of validations to be performed on the resulting image.
 * 
 */
public final class ImageTemplatePropertiesValidateArgs extends com.pulumi.resources.ResourceArgs {

    public static final ImageTemplatePropertiesValidateArgs Empty = new ImageTemplatePropertiesValidateArgs();

    /**
     * If validation fails and this field is set to false, output image(s) will not be distributed. This is the default behavior. If validation fails and this field is set to true, output image(s) will still be distributed. Please use this option with caution as it may result in bad images being distributed for use. In either case (true or false), the end to end image run will be reported as having failed in case of a validation failure. [Note: This field has no effect if validation succeeds.]
     * 
     */
    @Import(name="continueDistributeOnFailure")
    private @Nullable Output continueDistributeOnFailure;

    /**
     * @return If validation fails and this field is set to false, output image(s) will not be distributed. This is the default behavior. If validation fails and this field is set to true, output image(s) will still be distributed. Please use this option with caution as it may result in bad images being distributed for use. In either case (true or false), the end to end image run will be reported as having failed in case of a validation failure. [Note: This field has no effect if validation succeeds.]
     * 
     */
    public Optional> continueDistributeOnFailure() {
        return Optional.ofNullable(this.continueDistributeOnFailure);
    }

    /**
     * List of validations to be performed.
     * 
     */
    @Import(name="inVMValidations")
    private @Nullable Output> inVMValidations;

    /**
     * @return List of validations to be performed.
     * 
     */
    public Optional>> inVMValidations() {
        return Optional.ofNullable(this.inVMValidations);
    }

    /**
     * If this field is set to true, the image specified in the 'source' section will directly be validated. No separate build will be run to generate and then validate a customized image.
     * 
     */
    @Import(name="sourceValidationOnly")
    private @Nullable Output sourceValidationOnly;

    /**
     * @return If this field is set to true, the image specified in the 'source' section will directly be validated. No separate build will be run to generate and then validate a customized image.
     * 
     */
    public Optional> sourceValidationOnly() {
        return Optional.ofNullable(this.sourceValidationOnly);
    }

    private ImageTemplatePropertiesValidateArgs() {}

    private ImageTemplatePropertiesValidateArgs(ImageTemplatePropertiesValidateArgs $) {
        this.continueDistributeOnFailure = $.continueDistributeOnFailure;
        this.inVMValidations = $.inVMValidations;
        this.sourceValidationOnly = $.sourceValidationOnly;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(ImageTemplatePropertiesValidateArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private ImageTemplatePropertiesValidateArgs $;

        public Builder() {
            $ = new ImageTemplatePropertiesValidateArgs();
        }

        public Builder(ImageTemplatePropertiesValidateArgs defaults) {
            $ = new ImageTemplatePropertiesValidateArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param continueDistributeOnFailure If validation fails and this field is set to false, output image(s) will not be distributed. This is the default behavior. If validation fails and this field is set to true, output image(s) will still be distributed. Please use this option with caution as it may result in bad images being distributed for use. In either case (true or false), the end to end image run will be reported as having failed in case of a validation failure. [Note: This field has no effect if validation succeeds.]
         * 
         * @return builder
         * 
         */
        public Builder continueDistributeOnFailure(@Nullable Output continueDistributeOnFailure) {
            $.continueDistributeOnFailure = continueDistributeOnFailure;
            return this;
        }

        /**
         * @param continueDistributeOnFailure If validation fails and this field is set to false, output image(s) will not be distributed. This is the default behavior. If validation fails and this field is set to true, output image(s) will still be distributed. Please use this option with caution as it may result in bad images being distributed for use. In either case (true or false), the end to end image run will be reported as having failed in case of a validation failure. [Note: This field has no effect if validation succeeds.]
         * 
         * @return builder
         * 
         */
        public Builder continueDistributeOnFailure(Boolean continueDistributeOnFailure) {
            return continueDistributeOnFailure(Output.of(continueDistributeOnFailure));
        }

        /**
         * @param inVMValidations List of validations to be performed.
         * 
         * @return builder
         * 
         */
        public Builder inVMValidations(@Nullable Output> inVMValidations) {
            $.inVMValidations = inVMValidations;
            return this;
        }

        /**
         * @param inVMValidations List of validations to be performed.
         * 
         * @return builder
         * 
         */
        public Builder inVMValidations(List inVMValidations) {
            return inVMValidations(Output.of(inVMValidations));
        }

        /**
         * @param inVMValidations List of validations to be performed.
         * 
         * @return builder
         * 
         */
        public Builder inVMValidations(Object... inVMValidations) {
            return inVMValidations(List.of(inVMValidations));
        }

        /**
         * @param sourceValidationOnly If this field is set to true, the image specified in the 'source' section will directly be validated. No separate build will be run to generate and then validate a customized image.
         * 
         * @return builder
         * 
         */
        public Builder sourceValidationOnly(@Nullable Output sourceValidationOnly) {
            $.sourceValidationOnly = sourceValidationOnly;
            return this;
        }

        /**
         * @param sourceValidationOnly If this field is set to true, the image specified in the 'source' section will directly be validated. No separate build will be run to generate and then validate a customized image.
         * 
         * @return builder
         * 
         */
        public Builder sourceValidationOnly(Boolean sourceValidationOnly) {
            return sourceValidationOnly(Output.of(sourceValidationOnly));
        }

        public ImageTemplatePropertiesValidateArgs build() {
            $.continueDistributeOnFailure = Codegen.booleanProp("continueDistributeOnFailure").output().arg($.continueDistributeOnFailure).def(false).getNullable();
            $.sourceValidationOnly = Codegen.booleanProp("sourceValidationOnly").output().arg($.sourceValidationOnly).def(false).getNullable();
            return $;
        }
    }

}