ContainerAppsSourceControlArgs

data class ContainerAppsSourceControlArgs(val branch: Output<String>? = null, val containerAppName: Output<String>? = null, val githubActionConfiguration: Output<GithubActionConfigurationArgs>? = null, val repoUrl: Output<String>? = null, val resourceGroupName: Output<String>? = null, val sourceControlName: Output<String>? = null) : ConvertibleToJava<ContainerAppsSourceControlArgs>

Container App SourceControl. Uses Azure REST API version 2024-03-01. In version 2.x of the Azure Native provider, it used API version 2022-10-01. Other available API versions: 2022-10-01, 2022-11-01-preview, 2023-04-01-preview, 2023-05-01, 2023-05-02-preview, 2023-08-01-preview, 2023-11-02-preview, 2024-02-02-preview, 2024-08-02-preview, 2024-10-02-preview, 2025-01-01, 2025-02-02-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native app [ApiVersion]. See the ../../../version-guide/#accessing-any-api-version-via-local-packages for details.

Example Usage

Create or Update Container App SourceControl

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var containerAppsSourceControl = new AzureNative.App.ContainerAppsSourceControl("containerAppsSourceControl", new()
{
Branch = "master",
ContainerAppName = "testcanadacentral",
GithubActionConfiguration = new AzureNative.App.Inputs.GithubActionConfigurationArgs
{
AzureCredentials = new AzureNative.App.Inputs.AzureCredentialsArgs
{
ClientId = "<clientid>",
ClientSecret = "<clientsecret>",
Kind = "feaderated",
TenantId = "<tenantid>",
},
ContextPath = "./",
GithubPersonalAccessToken = "test",
Image = "image/tag",
RegistryInfo = new AzureNative.App.Inputs.RegistryInfoArgs
{
RegistryPassword = "<registrypassword>",
RegistryUrl = "test-registry.azurecr.io",
RegistryUserName = "test-registry",
},
},
RepoUrl = "https://github.com/xwang971/ghatest",
ResourceGroupName = "workerapps-rg-xj",
SourceControlName = "current",
});
});
package main
import (
app "github.com/pulumi/pulumi-azure-native-sdk/app/v3"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := app.NewContainerAppsSourceControl(ctx, "containerAppsSourceControl", &app.ContainerAppsSourceControlArgs{
Branch: pulumi.String("master"),
ContainerAppName: pulumi.String("testcanadacentral"),
GithubActionConfiguration: &app.GithubActionConfigurationArgs{
AzureCredentials: &app.AzureCredentialsArgs{
ClientId: pulumi.String("<clientid>"),
ClientSecret: pulumi.String("<clientsecret>"),
Kind: pulumi.String("feaderated"),
TenantId: pulumi.String("<tenantid>"),
},
ContextPath: pulumi.String("./"),
GithubPersonalAccessToken: pulumi.String("test"),
Image: pulumi.String("image/tag"),
RegistryInfo: &app.RegistryInfoArgs{
RegistryPassword: pulumi.String("<registrypassword>"),
RegistryUrl: pulumi.String("test-registry.azurecr.io"),
RegistryUserName: pulumi.String("test-registry"),
},
},
RepoUrl: pulumi.String("https://github.com/xwang971/ghatest"),
ResourceGroupName: pulumi.String("workerapps-rg-xj"),
SourceControlName: pulumi.String("current"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.app.ContainerAppsSourceControl;
import com.pulumi.azurenative.app.ContainerAppsSourceControlArgs;
import com.pulumi.azurenative.app.inputs.GithubActionConfigurationArgs;
import com.pulumi.azurenative.app.inputs.AzureCredentialsArgs;
import com.pulumi.azurenative.app.inputs.RegistryInfoArgs;
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 containerAppsSourceControl = new ContainerAppsSourceControl("containerAppsSourceControl", ContainerAppsSourceControlArgs.builder()
.branch("master")
.containerAppName("testcanadacentral")
.githubActionConfiguration(GithubActionConfigurationArgs.builder()
.azureCredentials(AzureCredentialsArgs.builder()
.clientId("<clientid>")
.clientSecret("<clientsecret>")
.kind("feaderated")
.tenantId("<tenantid>")
.build())
.contextPath("./")
.githubPersonalAccessToken("test")
.image("image/tag")
.registryInfo(RegistryInfoArgs.builder()
.registryPassword("<registrypassword>")
.registryUrl("test-registry.azurecr.io")
.registryUserName("test-registry")
.build())
.build())
.repoUrl("https://github.com/xwang971/ghatest")
.resourceGroupName("workerapps-rg-xj")
.sourceControlName("current")
.build());
}
}

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:app:ContainerAppsSourceControl current /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/containerApps/{containerAppName}/sourcecontrols/{sourceControlName}

Constructors

Link copied to clipboard
constructor(branch: Output<String>? = null, containerAppName: Output<String>? = null, githubActionConfiguration: Output<GithubActionConfigurationArgs>? = null, repoUrl: Output<String>? = null, resourceGroupName: Output<String>? = null, sourceControlName: Output<String>? = null)

Properties

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

The branch which will trigger the auto deployment

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

Name of the Container App.

Link copied to clipboard

Container App Revision Template with all possible settings and the defaults if user did not provide them. The defaults are populated as they were at the creation time

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

The repo url which will be integrated to ContainerApp.

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

The name of the resource group. The name is case insensitive.

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

Name of the Container App SourceControl.

Functions

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