-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Graza <[email protected]> Co-authored-by: ParthaI <[email protected]> Co-authored-by: khushboosharma <[email protected]> Co-authored-by: Khushboo <[email protected]>
- Loading branch information
1 parent
5fe0786
commit 7db0703
Showing
41 changed files
with
1,574 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
pipeline "assign_appservice_webapp_identity" { | ||
title = "Assign Managed Identity to AppService Web App" | ||
description = "Assign a managed identity to an Azure AppService Web App." | ||
|
||
tags = { | ||
type = "featured" | ||
} | ||
|
||
param "cred" { | ||
type = string | ||
description = local.cred_param_description | ||
default = "default" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = local.subscription_id_param_description | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = local.resource_group_param_description | ||
} | ||
|
||
param "app_name" { | ||
type = string | ||
description = "Name of the AppService web app." | ||
} | ||
|
||
step "container" "assign_appservice_webapp_identity" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = [ | ||
"webapp", "identity", "assign", | ||
"--resource-group", param.resource_group, | ||
"--name", param.app_name | ||
] | ||
|
||
env = credential.azure[param.cred].env | ||
} | ||
|
||
output "assign_appservice_webapp_identity" { | ||
description = "The assigned managed identity for the web app." | ||
value = jsondecode(step.container.assign_appservice_webapp_identity.stdout) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
pipeline "delete_app_service_plan" { | ||
title = "Delete App Service Plan" | ||
description = "Delete an Azure App Service Plan." | ||
|
||
param "cred" { | ||
type = string | ||
description = "The credentials to use for authentication." | ||
default = "default" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = "The Azure subscription ID." | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = "The name of the resource group that contains the App Service Plan." | ||
} | ||
|
||
param "service_plan_name" { | ||
type = string | ||
description = "The name of the App Service Plan that is being deleted." | ||
} | ||
|
||
step "container" "delete_app_service_plan" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = ["appservice", "plan", "delete", "--yes", "-g", param.resource_group, "--subscription", param.subscription_id, "-n", param.service_plan_name] | ||
|
||
env = credential.azure[param.cred].env | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
pipeline "set_config_appservice_webapp" { | ||
title = "Set Configuration for AppService Web App" | ||
description = "Set the configuration for an Azure Web App." | ||
|
||
tags = { | ||
type = "featured" | ||
} | ||
|
||
param "cred" { | ||
type = string | ||
description = local.cred_param_description | ||
default = "default" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = local.subscription_id_param_description | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = local.resource_group_param_description | ||
} | ||
|
||
param "app_name" { | ||
type = string | ||
description = "Name of the web app." | ||
} | ||
|
||
param "ftps_state" { | ||
type = string | ||
description = "FTPS state for the web app. Accepted values: disabled, FtpsOnly." | ||
optional = true | ||
} | ||
|
||
param "enable_http2" { | ||
type = bool | ||
description = "Enable HTTP/2 for the web app." | ||
optional = true | ||
} | ||
|
||
param "tls_version" { | ||
type = string | ||
description = "The TLS version to be updated." | ||
optional = true | ||
} | ||
|
||
step "container" "set_config_appservice_webapp" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = concat( | ||
["webapp", "config", "set", "--resource-group", param.resource_group, "--name", param.app_name], | ||
param.ftps_state != null ? concat(["--ftps-state", param.ftps_state]) : [], | ||
param.enable_http2 != null ? ["--http20-enabled", "true"] : [], | ||
param.tls_version != null ? concat(["--min-tls-version", param.tls_version]) : [] | ||
) | ||
env = credential.azure[param.cred].env | ||
} | ||
|
||
output "config_webapp" { | ||
description = "The updated configuration settings for the web app." | ||
value = jsondecode(step.container.set_config_appservice_webapp.stdout) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
pipeline "update_appservice_webapp" { | ||
title = "Update AppService Web App" | ||
description = "Update setting for an Azure Web App." | ||
|
||
tags = { | ||
type = "featured" | ||
} | ||
|
||
param "cred" { | ||
type = string | ||
description = local.cred_param_description | ||
default = "default" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = local.subscription_id_param_description | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = local.resource_group_param_description | ||
} | ||
|
||
param "app_name" { | ||
type = string | ||
description = "Name of the web app." | ||
} | ||
|
||
param "https_only" { | ||
type = bool | ||
description = "Enable or disable HTTPS only for the web app." | ||
} | ||
|
||
step "container" "update_appservice_webapp" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = [ | ||
"webapp", "update", | ||
"--resource-group", param.resource_group, | ||
"--name", param.app_name, | ||
"--set", "httpsOnly=${param.https_only}" | ||
] | ||
|
||
env = credential.azure[param.cred].env | ||
} | ||
|
||
output "update_appservice_webapp" { | ||
description = "The updated setting for the web app." | ||
value = jsondecode(step.container.update_appservice_webapp.stdout) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
pipeline "update_appservice_webapp_auth" { | ||
title = "Update AppService Web App Authentication" | ||
description = "Update the authentication settings of an Azure Web App." | ||
|
||
tags = { | ||
type = "featured" | ||
} | ||
|
||
param "cred" { | ||
type = string | ||
description = local.cred_param_description | ||
default = "default" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = local.subscription_id_param_description | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = local.resource_group_param_description | ||
} | ||
|
||
param "app_name" { | ||
type = string | ||
description = "Name of the web app." | ||
} | ||
|
||
param "enabled" { | ||
type = bool | ||
description = "Enable or disable authentication for the web app." | ||
} | ||
|
||
step "container" "update_appservice_webapp_auth" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = concat( | ||
["webapp", "auth", "update", "--resource-group", param.resource_group, "--name", param.app_name, "--enabled", tostring(param.enabled)] | ||
) | ||
|
||
env = credential.azure[param.cred].env | ||
} | ||
|
||
output "webapp_auth" { | ||
description = "The updated web app authentication settings." | ||
value = jsondecode(step.container.update_appservice_webapp_auth.stdout) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
pipelines/compute/delete_compute_virtual_machine_scale_set.fp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
pipeline "delete_virtual_machine_scale_set" { | ||
title = "Delete Virtual Machine Scale Set" | ||
description = "Delete an Azure Virtual Machine Scale Set." | ||
|
||
param "cred" { | ||
type = string | ||
description = "The credentials to use for authentication." | ||
default = "default" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = "The Azure subscription ID." | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = "The name of the resource group that contains the App Service Plan." | ||
} | ||
|
||
param "vmss_name" { | ||
type = string | ||
description = "The name of the Virtual Machine Scale Set." | ||
default = "test9000" | ||
} | ||
|
||
step "container" "delete_virtual_machine_scale_set" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = ["vmss", "delete", "-g", param.resource_group, "-n", param.vmss_name, "--subscription", param.subscription_id] | ||
|
||
env = credential.azure[param.cred].env | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
pipeline "resize_compute_virtual_machine" { | ||
title = "Resize Compute Virtual Machine" | ||
description = "Resize the properties of a VM." | ||
|
||
param "cred" { | ||
type = string | ||
description = local.cred_param_description | ||
default = "azure" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = local.subscription_id_param_description | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = local.resource_group_param_description | ||
} | ||
|
||
param "vm_name" { | ||
type = string | ||
description = "The name of the Virtual Machine." | ||
} | ||
|
||
param "new_size" { | ||
type = string | ||
description = "The new size for the Virtual Machine." | ||
} | ||
|
||
step "container" "resize_compute_virtual_machine" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = [ | ||
"vm", "resize", | ||
"-g", param.resource_group, | ||
"-n", param.vm_name, | ||
"--subscription", param.subscription_id, | ||
"--size", param.new_size | ||
] | ||
|
||
env = credential.azure[param.cred].env | ||
} | ||
|
||
output "virtual_machine" { | ||
description = "The resized compute virtual machine." | ||
value = jsondecode(step.container.resize_compute_virtual_machine.stdout) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
pipeline "update_compute_snapshot" { | ||
title = "Update Compute Snapshot" | ||
description = "Update a compute snapshot." | ||
|
||
param "cred" { | ||
type = string | ||
description = local.cred_param_description | ||
default = "default" | ||
} | ||
|
||
param "subscription_id" { | ||
type = string | ||
description = local.subscription_id_param_description | ||
} | ||
|
||
param "resource_group" { | ||
type = string | ||
description = local.resource_group_param_description | ||
} | ||
|
||
param "sku" { | ||
type = string | ||
description = "The SKU tier to be updated." | ||
} | ||
|
||
param "snapshot_name" { | ||
type = string | ||
description = "The name of the compute snapshot that is being deleted." | ||
} | ||
|
||
step "container" "update_compute_snapshot" { | ||
image = "ghcr.io/turbot/flowpipe-image-azure-cli" | ||
cmd = ["snapshot", "update", "-g", param.resource_group, "-n", param.snapshot_name, "--subscription", param.subscription_id, "--sku", param.sku] | ||
|
||
env = credential.azure[param.cred].env | ||
} | ||
|
||
} |
Oops, something went wrong.