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

com.pulumi.azure.hpc.outputs.CacheAccessPolicyAccessRule Maven / Gradle / Ivy

Go to download

A Pulumi package for creating and managing Microsoft Azure cloud resources, based on the Terraform azurerm provider. We recommend using the [Azure Native provider](https://github.com/pulumi/pulumi-azure-native) to provision Azure infrastructure. Azure Native provides complete coverage of Azure resources and same-day access to new resources and resource updates.

There is a newer version: 6.10.0-alpha.1731737215
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.azure.hpc.outputs;

import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class CacheAccessPolicyAccessRule {
    /**
     * @return The access level for this rule. Possible values are: `rw`, `ro`, `no`.
     * 
     */
    private String access;
    /**
     * @return The anonymous GID used when `root_squash_enabled` is `true`.
     * 
     */
    private @Nullable Integer anonymousGid;
    /**
     * @return The anonymous UID used when `root_squash_enabled` is `true`.
     * 
     */
    private @Nullable Integer anonymousUid;
    /**
     * @return The filter applied to the `scope` for this rule. The filter's format depends on its scope: `default` scope matches all clients and has no filter value; `network` scope takes a CIDR format; `host` takes an IP address or fully qualified domain name. If a client does not match any filter rule and there is no default rule, access is denied.
     * 
     */
    private @Nullable String filter;
    /**
     * @return Whether to enable [root squash](https://docs.microsoft.com/azure/hpc-cache/access-policies#root-squash)?
     * 
     */
    private @Nullable Boolean rootSquashEnabled;
    /**
     * @return The scope of this rule. The `scope` and (potentially) the `filter` determine which clients match the rule. Possible values are: `default`, `network`, `host`.
     * 
     * > **NOTE:** Each `access_rule` should set a unique `scope`.
     * 
     */
    private String scope;
    /**
     * @return Whether allow access to subdirectories under the root export?
     * 
     */
    private @Nullable Boolean submountAccessEnabled;
    /**
     * @return Whether [SUID](https://docs.microsoft.com/azure/hpc-cache/access-policies#suid) is allowed?
     * 
     */
    private @Nullable Boolean suidEnabled;

    private CacheAccessPolicyAccessRule() {}
    /**
     * @return The access level for this rule. Possible values are: `rw`, `ro`, `no`.
     * 
     */
    public String access() {
        return this.access;
    }
    /**
     * @return The anonymous GID used when `root_squash_enabled` is `true`.
     * 
     */
    public Optional anonymousGid() {
        return Optional.ofNullable(this.anonymousGid);
    }
    /**
     * @return The anonymous UID used when `root_squash_enabled` is `true`.
     * 
     */
    public Optional anonymousUid() {
        return Optional.ofNullable(this.anonymousUid);
    }
    /**
     * @return The filter applied to the `scope` for this rule. The filter's format depends on its scope: `default` scope matches all clients and has no filter value; `network` scope takes a CIDR format; `host` takes an IP address or fully qualified domain name. If a client does not match any filter rule and there is no default rule, access is denied.
     * 
     */
    public Optional filter() {
        return Optional.ofNullable(this.filter);
    }
    /**
     * @return Whether to enable [root squash](https://docs.microsoft.com/azure/hpc-cache/access-policies#root-squash)?
     * 
     */
    public Optional rootSquashEnabled() {
        return Optional.ofNullable(this.rootSquashEnabled);
    }
    /**
     * @return The scope of this rule. The `scope` and (potentially) the `filter` determine which clients match the rule. Possible values are: `default`, `network`, `host`.
     * 
     * > **NOTE:** Each `access_rule` should set a unique `scope`.
     * 
     */
    public String scope() {
        return this.scope;
    }
    /**
     * @return Whether allow access to subdirectories under the root export?
     * 
     */
    public Optional submountAccessEnabled() {
        return Optional.ofNullable(this.submountAccessEnabled);
    }
    /**
     * @return Whether [SUID](https://docs.microsoft.com/azure/hpc-cache/access-policies#suid) is allowed?
     * 
     */
    public Optional suidEnabled() {
        return Optional.ofNullable(this.suidEnabled);
    }

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

    public static Builder builder(CacheAccessPolicyAccessRule defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private String access;
        private @Nullable Integer anonymousGid;
        private @Nullable Integer anonymousUid;
        private @Nullable String filter;
        private @Nullable Boolean rootSquashEnabled;
        private String scope;
        private @Nullable Boolean submountAccessEnabled;
        private @Nullable Boolean suidEnabled;
        public Builder() {}
        public Builder(CacheAccessPolicyAccessRule defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.access = defaults.access;
    	      this.anonymousGid = defaults.anonymousGid;
    	      this.anonymousUid = defaults.anonymousUid;
    	      this.filter = defaults.filter;
    	      this.rootSquashEnabled = defaults.rootSquashEnabled;
    	      this.scope = defaults.scope;
    	      this.submountAccessEnabled = defaults.submountAccessEnabled;
    	      this.suidEnabled = defaults.suidEnabled;
        }

        @CustomType.Setter
        public Builder access(String access) {
            if (access == null) {
              throw new MissingRequiredPropertyException("CacheAccessPolicyAccessRule", "access");
            }
            this.access = access;
            return this;
        }
        @CustomType.Setter
        public Builder anonymousGid(@Nullable Integer anonymousGid) {

            this.anonymousGid = anonymousGid;
            return this;
        }
        @CustomType.Setter
        public Builder anonymousUid(@Nullable Integer anonymousUid) {

            this.anonymousUid = anonymousUid;
            return this;
        }
        @CustomType.Setter
        public Builder filter(@Nullable String filter) {

            this.filter = filter;
            return this;
        }
        @CustomType.Setter
        public Builder rootSquashEnabled(@Nullable Boolean rootSquashEnabled) {

            this.rootSquashEnabled = rootSquashEnabled;
            return this;
        }
        @CustomType.Setter
        public Builder scope(String scope) {
            if (scope == null) {
              throw new MissingRequiredPropertyException("CacheAccessPolicyAccessRule", "scope");
            }
            this.scope = scope;
            return this;
        }
        @CustomType.Setter
        public Builder submountAccessEnabled(@Nullable Boolean submountAccessEnabled) {

            this.submountAccessEnabled = submountAccessEnabled;
            return this;
        }
        @CustomType.Setter
        public Builder suidEnabled(@Nullable Boolean suidEnabled) {

            this.suidEnabled = suidEnabled;
            return this;
        }
        public CacheAccessPolicyAccessRule build() {
            final var _resultValue = new CacheAccessPolicyAccessRule();
            _resultValue.access = access;
            _resultValue.anonymousGid = anonymousGid;
            _resultValue.anonymousUid = anonymousUid;
            _resultValue.filter = filter;
            _resultValue.rootSquashEnabled = rootSquashEnabled;
            _resultValue.scope = scope;
            _resultValue.submountAccessEnabled = submountAccessEnabled;
            _resultValue.suidEnabled = suidEnabled;
            return _resultValue;
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy