BitbucketServerConfigArgs

data class BitbucketServerConfigArgs(val apiKey: Output<String>? = null, val configId: Output<String>? = null, val connectedRepositories: Output<List<BitbucketServerConfigConnectedRepositoryArgs>>? = null, val hostUri: Output<String>? = null, val location: Output<String>? = null, val peeredNetwork: Output<String>? = null, val project: Output<String>? = null, val secrets: Output<BitbucketServerConfigSecretsArgs>? = null, val sslCa: Output<String>? = null, val username: Output<String>? = null) : ConvertibleToJava<BitbucketServerConfigArgs>

BitbucketServerConfig represents the configuration for a Bitbucket Server. To get more information about BitbucketServerConfig, see:

Example Usage

Cloudbuild Bitbucket Server Config

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.cloudbuild.BitbucketServerConfig;
import com.pulumi.gcp.cloudbuild.BitbucketServerConfigArgs;
import com.pulumi.gcp.cloudbuild.inputs.BitbucketServerConfigSecretsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var bbs_config = new BitbucketServerConfig("bbs-config", BitbucketServerConfigArgs.builder()
.apiKey("<api-key>")
.configId("bbs-config")
.hostUri("https://bbs.com")
.location("us-central1")
.secrets(BitbucketServerConfigSecretsArgs.builder()
.adminAccessTokenVersionName("projects/myProject/secrets/mybbspat/versions/1")
.readAccessTokenVersionName("projects/myProject/secrets/mybbspat/versions/1")
.webhookSecretVersionName("projects/myProject/secrets/mybbspat/versions/1")
.build())
.username("test")
.build());
}
}

Cloudbuild Bitbucket Server Config Repositories

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.cloudbuild.BitbucketServerConfig;
import com.pulumi.gcp.cloudbuild.BitbucketServerConfigArgs;
import com.pulumi.gcp.cloudbuild.inputs.BitbucketServerConfigConnectedRepositoryArgs;
import com.pulumi.gcp.cloudbuild.inputs.BitbucketServerConfigSecretsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var bbs_config_with_repos = new BitbucketServerConfig("bbs-config-with-repos", BitbucketServerConfigArgs.builder()
.apiKey("<api-key>")
.configId("bbs-config")
.connectedRepositories(
BitbucketServerConfigConnectedRepositoryArgs.builder()
.projectKey("DEV")
.repoSlug("repo1")
.build(),
BitbucketServerConfigConnectedRepositoryArgs.builder()
.projectKey("PROD")
.repoSlug("repo1")
.build())
.hostUri("https://bbs.com")
.location("us-central1")
.secrets(BitbucketServerConfigSecretsArgs.builder()
.adminAccessTokenVersionName("projects/myProject/secrets/mybbspat/versions/1")
.readAccessTokenVersionName("projects/myProject/secrets/mybbspat/versions/1")
.webhookSecretVersionName("projects/myProject/secrets/mybbspat/versions/1")
.build())
.username("test")
.build());
}
}

Import

BitbucketServerConfig can be imported using any of these accepted formats

$ pulumi import gcp:cloudbuild/bitbucketServerConfig:BitbucketServerConfig default projects/{{project}}/locations/{{location}}/bitbucketServerConfigs/{{config_id}}
$ pulumi import gcp:cloudbuild/bitbucketServerConfig:BitbucketServerConfig default {{project}}/{{location}}/{{config_id}}
$ pulumi import gcp:cloudbuild/bitbucketServerConfig:BitbucketServerConfig default {{location}}/{{config_id}}

Constructors

Link copied to clipboard
constructor(apiKey: Output<String>? = null, configId: Output<String>? = null, connectedRepositories: Output<List<BitbucketServerConfigConnectedRepositoryArgs>>? = null, hostUri: Output<String>? = null, location: Output<String>? = null, peeredNetwork: Output<String>? = null, project: Output<String>? = null, secrets: Output<BitbucketServerConfigSecretsArgs>? = null, sslCa: Output<String>? = null, username: Output<String>? = null)

Properties

Link copied to clipboard
val apiKey: Output<String>? = null

Immutable. API Key that will be attached to webhook. Once this field has been set, it cannot be changed. Changing this field will result in deleting/ recreating the resource.

Link copied to clipboard
val configId: Output<String>? = null

The ID to use for the BitbucketServerConfig, which will become the final component of the BitbucketServerConfig's resource name.

Link copied to clipboard

Connected Bitbucket Server repositories for this config. Structure is documented below.

Link copied to clipboard
val hostUri: Output<String>? = null

Immutable. The URI of the Bitbucket Server host. Once this field has been set, it cannot be changed. If you need to change it, please create another BitbucketServerConfig.

Link copied to clipboard
val location: Output<String>? = null

The location of this bitbucket server config.

Link copied to clipboard
val peeredNetwork: Output<String>? = null

The network to be used when reaching out to the Bitbucket Server instance. The VPC network must be enabled for private service connection. This should be set if the Bitbucket Server instance is hosted on-premises and not reachable by public internet. If this field is left empty, no network peering will occur and calls to the Bitbucket Server instance will be made over the public internet. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number or id and {network} is the name of a VPC network in the project.

Link copied to clipboard
val project: Output<String>? = null

The ID of the project in which the resource belongs. If it is not provided, the provider project is used.

Link copied to clipboard

Secret Manager secrets needed by the config. Structure is documented below.

Link copied to clipboard
val sslCa: Output<String>? = null

SSL certificate to use for requests to Bitbucket Server. The format should be PEM format but the extension can be one of .pem, .cer, or .crt.

Link copied to clipboard
val username: Output<String>? = null

Username of the account Cloud Build will use on Bitbucket Server.

Functions

Link copied to clipboard
open override fun toJava(): BitbucketServerConfigArgs