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

com.pulumi.kubernetes.policy.v1beta1.inputs.RunAsGroupStrategyOptionsArgs Maven / Gradle / Ivy

There is a newer version: 4.19.0-alpha.1730750641
Show newest version
// *** 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.kubernetes.policy.v1beta1.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import com.pulumi.kubernetes.policy.v1beta1.inputs.IDRangeArgs;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


/**
 * RunAsGroupStrategyOptions defines the strategy type and any options used to create the strategy.
 * 
 */
public final class RunAsGroupStrategyOptionsArgs extends com.pulumi.resources.ResourceArgs {

    public static final RunAsGroupStrategyOptionsArgs Empty = new RunAsGroupStrategyOptionsArgs();

    /**
     * ranges are the allowed ranges of gids that may be used. If you would like to force a single gid then supply a single range with the same start and end. Required for MustRunAs.
     * 
     */
    @Import(name="ranges")
    private @Nullable Output> ranges;

    /**
     * @return ranges are the allowed ranges of gids that may be used. If you would like to force a single gid then supply a single range with the same start and end. Required for MustRunAs.
     * 
     */
    public Optional>> ranges() {
        return Optional.ofNullable(this.ranges);
    }

    /**
     * rule is the strategy that will dictate the allowable RunAsGroup values that may be set.
     * 
     */
    @Import(name="rule", required=true)
    private Output rule;

    /**
     * @return rule is the strategy that will dictate the allowable RunAsGroup values that may be set.
     * 
     */
    public Output rule() {
        return this.rule;
    }

    private RunAsGroupStrategyOptionsArgs() {}

    private RunAsGroupStrategyOptionsArgs(RunAsGroupStrategyOptionsArgs $) {
        this.ranges = $.ranges;
        this.rule = $.rule;
    }

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

    public static final class Builder {
        private RunAsGroupStrategyOptionsArgs $;

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

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

        /**
         * @param ranges ranges are the allowed ranges of gids that may be used. If you would like to force a single gid then supply a single range with the same start and end. Required for MustRunAs.
         * 
         * @return builder
         * 
         */
        public Builder ranges(@Nullable Output> ranges) {
            $.ranges = ranges;
            return this;
        }

        /**
         * @param ranges ranges are the allowed ranges of gids that may be used. If you would like to force a single gid then supply a single range with the same start and end. Required for MustRunAs.
         * 
         * @return builder
         * 
         */
        public Builder ranges(List ranges) {
            return ranges(Output.of(ranges));
        }

        /**
         * @param ranges ranges are the allowed ranges of gids that may be used. If you would like to force a single gid then supply a single range with the same start and end. Required for MustRunAs.
         * 
         * @return builder
         * 
         */
        public Builder ranges(IDRangeArgs... ranges) {
            return ranges(List.of(ranges));
        }

        /**
         * @param rule rule is the strategy that will dictate the allowable RunAsGroup values that may be set.
         * 
         * @return builder
         * 
         */
        public Builder rule(Output rule) {
            $.rule = rule;
            return this;
        }

        /**
         * @param rule rule is the strategy that will dictate the allowable RunAsGroup values that may be set.
         * 
         * @return builder
         * 
         */
        public Builder rule(String rule) {
            return rule(Output.of(rule));
        }

        public RunAsGroupStrategyOptionsArgs build() {
            if ($.rule == null) {
                throw new MissingRequiredPropertyException("RunAsGroupStrategyOptionsArgs", "rule");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy