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

io.quarkiverse.googlecloudservices.common.GcpBootstrapConfiguration Maven / Gradle / Ivy

There is a newer version: 2.13.0
Show newest version
package io.quarkiverse.googlecloudservices.common;

import java.util.Optional;

import io.quarkus.runtime.annotations.ConfigItem;
import io.quarkus.runtime.annotations.ConfigPhase;
import io.quarkus.runtime.annotations.ConfigRoot;

/**
 * Bootstrap configuration
 *
 * We need these properties at bootstrap to be able to register the secret manager config source that needs it.
 */
@ConfigRoot(name = "google.cloud", phase = ConfigPhase.BOOTSTRAP)
public class GcpBootstrapConfiguration {
    /**
     * Google Cloud project ID.
     * It defaults to `ServiceOptions.getDefaultProjectId()`,
     * so to the project ID corresponding to the default credentials if the default credentials are set, otherwise null.
     */
    @ConfigItem(defaultValueDocumentation = "ServiceOptions.getDefaultProjectId()")
    public Optional projectId;

    /**
     * Google Cloud service account file location.
     */
    @ConfigItem
    public Optional serviceAccountLocation;

    /**
     * Google Cloud service account base64 encoded content.
     */
    @ConfigItem
    public Optional serviceAccountEncodedKey;

    /**
     * Enable Google Cloud access token authentication
     * For example, the access token which is returned as part of OpenId Connect Authorization Code Flow
     * may be used to access Google Cloud services on behalf of the authenticated user.
     *
     * Note that if a service account location is configured then the access token will be ignored even if this property is
     * enabled.
     *
     * Disable this property if the default Google Cloud authentication is required.
     */
    @ConfigItem(defaultValue = "true")
    public boolean accessTokenEnabled = true;
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy