SourceControlArgs

data class SourceControlArgs(val appId: Output<String>? = null, val branch: Output<String>? = null, val githubActionConfiguration: Output<SourceControlGithubActionConfigurationArgs>? = null, val repoUrl: Output<String>? = null, val rollbackEnabled: Output<Boolean>? = null, val useLocalGit: Output<Boolean>? = null, val useManualIntegration: Output<Boolean>? = null, val useMercurial: Output<Boolean>? = null) : ConvertibleToJava<SourceControlArgs>

Manages an App Service Web App or Function App Source Control Configuration.

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.appservice.ServicePlan;
import com.pulumi.azure.appservice.ServicePlanArgs;
import com.pulumi.azure.appservice.LinuxWebApp;
import com.pulumi.azure.appservice.LinuxWebAppArgs;
import com.pulumi.azure.appservice.inputs.LinuxWebAppSiteConfigArgs;
import com.pulumi.azure.appservice.SourceControl;
import com.pulumi.azure.appservice.SourceControlArgs;
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 exampleResourceGroup = new ResourceGroup("exampleResourceGroup", ResourceGroupArgs.builder()
.location("West Europe")
.build());
var exampleServicePlan = new ServicePlan("exampleServicePlan", ServicePlanArgs.builder()
.resourceGroupName(exampleResourceGroup.name())
.location(exampleResourceGroup.location())
.osType("Linux")
.skuName("P1v2")
.build());
var exampleLinuxWebApp = new LinuxWebApp("exampleLinuxWebApp", LinuxWebAppArgs.builder()
.resourceGroupName(exampleResourceGroup.name())
.location(exampleServicePlan.location())
.servicePlanId(exampleServicePlan.id())
.siteConfig()
.build());
var exampleSourceControl = new SourceControl("exampleSourceControl", SourceControlArgs.builder()
.appId(exampleLinuxWebApp.id())
.repoUrl("https://github.com/Azure-Samples/python-docs-hello-world")
.branch("master")
.build());
}
}

Import

App Service Source Controls can be imported using the resource id, e.g.

$ pulumi import azure:appservice/sourceControl:SourceControl example /subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/resGroup1/providers/Microsoft.Web/sites/site1

Constructors

Link copied to clipboard
fun SourceControlArgs(appId: Output<String>? = null, branch: Output<String>? = null, githubActionConfiguration: Output<SourceControlGithubActionConfigurationArgs>? = null, repoUrl: Output<String>? = null, rollbackEnabled: Output<Boolean>? = null, useLocalGit: Output<Boolean>? = null, useManualIntegration: Output<Boolean>? = null, useMercurial: Output<Boolean>? = null)

Functions

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

Properties

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

The ID of the Windows or Linux Web App. Changing this forces a new resource to be created.

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

The branch name to use for deployments. Changing this forces a new resource to be created.

Link copied to clipboard

A github_action_configuration block as defined below. Changing this forces a new resource to be created.

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

The URL for the repository. Changing this forces a new resource to be created.

Link copied to clipboard
val rollbackEnabled: Output<Boolean>? = null

Should the Deployment Rollback be enabled? Defaults to false. Changing this forces a new resource to be created.

Link copied to clipboard
val useLocalGit: Output<Boolean>? = null

Should the App use local Git configuration. Changing this forces a new resource to be created.

Link copied to clipboard
val useManualIntegration: Output<Boolean>? = null

Should code be deployed manually. Set to false to enable continuous integration, such as webhooks into online repos such as GitHub. Defaults to false. Changing this forces a new resource to be created.

Link copied to clipboard
val useMercurial: Output<Boolean>? = null

The repository specified is Mercurial. Defaults to false. Changing this forces a new resource to be created.