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

com.pulumi.dockerbuild.inputs.RegistryArgs Maven / Gradle / Ivy

Go to download

A Pulumi provider for building modern Docker images with buildx and BuildKit.

There is a newer version: 0.1.0-alpha.1729468870
Show newest version
// *** WARNING: this file was generated by pulumi. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.dockerbuild.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class RegistryArgs extends com.pulumi.resources.ResourceArgs {

    public static final RegistryArgs Empty = new RegistryArgs();

    /**
     * The registry's address (e.g. "docker.io").
     * 
     */
    @Import(name="address", required=true)
    private Output address;

    /**
     * @return The registry's address (e.g. "docker.io").
     * 
     */
    public Output address() {
        return this.address;
    }

    /**
     * Password or token for the registry.
     * 
     */
    @Import(name="password")
    private @Nullable Output password;

    /**
     * @return Password or token for the registry.
     * 
     */
    public Optional> password() {
        return Optional.ofNullable(this.password);
    }

    /**
     * Username for the registry.
     * 
     */
    @Import(name="username")
    private @Nullable Output username;

    /**
     * @return Username for the registry.
     * 
     */
    public Optional> username() {
        return Optional.ofNullable(this.username);
    }

    private RegistryArgs() {}

    private RegistryArgs(RegistryArgs $) {
        this.address = $.address;
        this.password = $.password;
        this.username = $.username;
    }

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

    public static final class Builder {
        private RegistryArgs $;

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

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

        /**
         * @param address The registry's address (e.g. "docker.io").
         * 
         * @return builder
         * 
         */
        public Builder address(Output address) {
            $.address = address;
            return this;
        }

        /**
         * @param address The registry's address (e.g. "docker.io").
         * 
         * @return builder
         * 
         */
        public Builder address(String address) {
            return address(Output.of(address));
        }

        /**
         * @param password Password or token for the registry.
         * 
         * @return builder
         * 
         */
        public Builder password(@Nullable Output password) {
            $.password = password;
            return this;
        }

        /**
         * @param password Password or token for the registry.
         * 
         * @return builder
         * 
         */
        public Builder password(String password) {
            return password(Output.of(password));
        }

        /**
         * @param username Username for the registry.
         * 
         * @return builder
         * 
         */
        public Builder username(@Nullable Output username) {
            $.username = username;
            return this;
        }

        /**
         * @param username Username for the registry.
         * 
         * @return builder
         * 
         */
        public Builder username(String username) {
            return username(Output.of(username));
        }

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

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy