Skip to content

Commit

Permalink
Add defaults for Azure Spring Apps sub-resources
Browse files Browse the repository at this point in the history
  • Loading branch information
chutch1122 authored and danielrbradley committed Oct 26, 2022
1 parent d398079 commit d07f6b2
Show file tree
Hide file tree
Showing 385 changed files with 67,920 additions and 6,722 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

## HEAD (Unreleased)

- Adds default values to defaultResourcesState.go for Azure Spring Apps sub-resources
- New resources:
- azure-native:appplatform:BuildServiceAgentPool
- azure-native:appplatform:ConfigServer
- azure-native:appplatform:MonitoringSetting

## 1.83.1 (2022-10-25)

- Fix panic when validating `az` CLI version [#2049](https://github.com/pulumi/pulumi-azure-native/pull/2049)
Expand Down
48 changes: 24 additions & 24 deletions provider/cmd/pulumi-resource-azure-native/schema.json

Large diffs are not rendered by default.

33 changes: 26 additions & 7 deletions provider/pkg/openapi/defaultResourcesState.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ var defaultResourcesStateRaw = map[string]map[string]interface{}{
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/advisors/{advisorName}": {
"autoExecuteStatus": "Default",
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/azureADOnlyAuthentications/{authenticationName}":{
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/azureADOnlyAuthentications/{authenticationName}": {
"azureADOnlyAuthentication": false,
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/advisors/{advisorName}": {
Expand All @@ -53,11 +53,11 @@ var defaultResourcesStateRaw = map[string]map[string]interface{}{
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/auditingSettings/{blobAuditingPolicyName}": {
"state": "Disabled",
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies/{policyName}": {
"weeklyRetention": "PT0S",
"monthlyRetention":"PT0S",
"yearlyRetention": "PT0S",
"weekOfYear": 1,
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies/{policyName}": {
"weeklyRetention": "PT0S",
"monthlyRetention": "PT0S",
"yearlyRetention": "PT0S",
"weekOfYear": 1,
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}": {
"retentionDays": 7,
Expand Down Expand Up @@ -121,7 +121,26 @@ var defaultResourcesStateRaw = map[string]map[string]interface{}{
"subnetResourceId": "*", // This is going to be a resource ID, so we choose accept any value here.
"swiftSupported": true,
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web": {},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web": {},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/monitoringSettings/default": {
"properties": map[string]interface{}{
"traceEnabled": false,
"appInsightsInstrumentationKey": "",
"appInsightsSamplingRate": 10.0,
},
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/configServers/default": {
"properties": map[string]interface{}{
"configServer": map[string]string{},
},
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/buildServices/{buildServiceName}/agentPools/{agentPoolName}": {
"properties": map[string]interface{}{
"poolSize": map[string]interface{}{
"name": "S1",
},
},
},
}

// defaultResourcesStateNormalized maps normalized paths of resources to default state of a resource. The default state is
Expand Down
115 changes: 115 additions & 0 deletions sdk/dotnet/AppPlatform/V20200701/ConfigServer.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
// *** WARNING: this file was generated by the Pulumi SDK Generator. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.AzureNative.AppPlatform.V20200701
{
/// <summary>
/// Config Server resource
/// </summary>
[AzureNativeResourceType("azure-native:appplatform/v20200701:ConfigServer")]
public partial class ConfigServer : global::Pulumi.CustomResource
{
/// <summary>
/// The name of the resource.
/// </summary>
[Output("name")]
public Output<string> Name { get; private set; } = null!;

/// <summary>
/// Properties of the Config Server resource
/// </summary>
[Output("properties")]
public Output<Outputs.ConfigServerPropertiesResponse> Properties { get; private set; } = null!;

/// <summary>
/// The type of the resource.
/// </summary>
[Output("type")]
public Output<string> Type { get; private set; } = null!;


/// <summary>
/// Create a ConfigServer resource with the given unique name, arguments, and options.
/// </summary>
///
/// <param name="name">The unique name of the resource</param>
/// <param name="args">The arguments used to populate this resource's properties</param>
/// <param name="options">A bag of options that control this resource's behavior</param>
public ConfigServer(string name, ConfigServerArgs args, CustomResourceOptions? options = null)
: base("azure-native:appplatform/v20200701:ConfigServer", name, args ?? new ConfigServerArgs(), MakeResourceOptions(options, ""))
{
}

private ConfigServer(string name, Input<string> id, CustomResourceOptions? options = null)
: base("azure-native:appplatform/v20200701:ConfigServer", name, null, MakeResourceOptions(options, id))
{
}

private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input<string>? id)
{
var defaultOptions = new CustomResourceOptions
{
Version = Utilities.Version,
Aliases =
{
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20201101preview:ConfigServer"},
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20210601preview:ConfigServer"},
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20210901preview:ConfigServer"},
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20220101preview:ConfigServer"},
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20220301preview:ConfigServer"},
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20220401:ConfigServer"},
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20220501preview:ConfigServer"},
new global::Pulumi.Alias { Type = "azure-native:appplatform/v20220901preview:ConfigServer"},
},
};
var merged = CustomResourceOptions.Merge(defaultOptions, options);
// Override the ID if one was specified for consistency with other language SDKs.
merged.Id = id ?? merged.Id;
return merged;
}
/// <summary>
/// Get an existing ConfigServer resource's state with the given name, ID, and optional extra
/// properties used to qualify the lookup.
/// </summary>
///
/// <param name="name">The unique name of the resulting resource.</param>
/// <param name="id">The unique provider ID of the resource to lookup.</param>
/// <param name="options">A bag of options that control this resource's behavior</param>
public static ConfigServer Get(string name, Input<string> id, CustomResourceOptions? options = null)
{
return new ConfigServer(name, id, options);
}
}

public sealed class ConfigServerArgs : global::Pulumi.ResourceArgs
{
/// <summary>
/// Properties of the Config Server resource
/// </summary>
[Input("properties")]
public Input<Inputs.ConfigServerPropertiesArgs>? Properties { get; set; }

/// <summary>
/// The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
/// </summary>
[Input("resourceGroupName", required: true)]
public Input<string> ResourceGroupName { get; set; } = null!;

/// <summary>
/// The name of the Service resource.
/// </summary>
[Input("serviceName", required: true)]
public Input<string> ServiceName { get; set; } = null!;

public ConfigServerArgs()
{
}
public static new ConfigServerArgs Empty => new ConfigServerArgs();
}
}
105 changes: 105 additions & 0 deletions sdk/dotnet/AppPlatform/V20200701/GetConfigServer.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
// *** WARNING: this file was generated by the Pulumi SDK Generator. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.AzureNative.AppPlatform.V20200701
{
public static class GetConfigServer
{
/// <summary>
/// Config Server resource
/// </summary>
public static Task<GetConfigServerResult> InvokeAsync(GetConfigServerArgs args, InvokeOptions? options = null)
=> global::Pulumi.Deployment.Instance.InvokeAsync<GetConfigServerResult>("azure-native:appplatform/v20200701:getConfigServer", args ?? new GetConfigServerArgs(), options.WithDefaults());

/// <summary>
/// Config Server resource
/// </summary>
public static Output<GetConfigServerResult> Invoke(GetConfigServerInvokeArgs args, InvokeOptions? options = null)
=> global::Pulumi.Deployment.Instance.Invoke<GetConfigServerResult>("azure-native:appplatform/v20200701:getConfigServer", args ?? new GetConfigServerInvokeArgs(), options.WithDefaults());
}


public sealed class GetConfigServerArgs : global::Pulumi.InvokeArgs
{
/// <summary>
/// The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
/// </summary>
[Input("resourceGroupName", required: true)]
public string ResourceGroupName { get; set; } = null!;

/// <summary>
/// The name of the Service resource.
/// </summary>
[Input("serviceName", required: true)]
public string ServiceName { get; set; } = null!;

public GetConfigServerArgs()
{
}
public static new GetConfigServerArgs Empty => new GetConfigServerArgs();
}

public sealed class GetConfigServerInvokeArgs : global::Pulumi.InvokeArgs
{
/// <summary>
/// The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
/// </summary>
[Input("resourceGroupName", required: true)]
public Input<string> ResourceGroupName { get; set; } = null!;

/// <summary>
/// The name of the Service resource.
/// </summary>
[Input("serviceName", required: true)]
public Input<string> ServiceName { get; set; } = null!;

public GetConfigServerInvokeArgs()
{
}
public static new GetConfigServerInvokeArgs Empty => new GetConfigServerInvokeArgs();
}


[OutputType]
public sealed class GetConfigServerResult
{
/// <summary>
/// Fully qualified resource Id for the resource.
/// </summary>
public readonly string Id;
/// <summary>
/// The name of the resource.
/// </summary>
public readonly string Name;
/// <summary>
/// Properties of the Config Server resource
/// </summary>
public readonly Outputs.ConfigServerPropertiesResponse Properties;
/// <summary>
/// The type of the resource.
/// </summary>
public readonly string Type;

[OutputConstructor]
private GetConfigServerResult(
string id,

string name,

Outputs.ConfigServerPropertiesResponse properties,

string type)
{
Id = id;
Name = name;
Properties = properties;
Type = type;
}
}
}
105 changes: 105 additions & 0 deletions sdk/dotnet/AppPlatform/V20200701/GetMonitoringSetting.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
// *** WARNING: this file was generated by the Pulumi SDK Generator. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.AzureNative.AppPlatform.V20200701
{
public static class GetMonitoringSetting
{
/// <summary>
/// Monitoring Setting resource
/// </summary>
public static Task<GetMonitoringSettingResult> InvokeAsync(GetMonitoringSettingArgs args, InvokeOptions? options = null)
=> global::Pulumi.Deployment.Instance.InvokeAsync<GetMonitoringSettingResult>("azure-native:appplatform/v20200701:getMonitoringSetting", args ?? new GetMonitoringSettingArgs(), options.WithDefaults());

/// <summary>
/// Monitoring Setting resource
/// </summary>
public static Output<GetMonitoringSettingResult> Invoke(GetMonitoringSettingInvokeArgs args, InvokeOptions? options = null)
=> global::Pulumi.Deployment.Instance.Invoke<GetMonitoringSettingResult>("azure-native:appplatform/v20200701:getMonitoringSetting", args ?? new GetMonitoringSettingInvokeArgs(), options.WithDefaults());
}


public sealed class GetMonitoringSettingArgs : global::Pulumi.InvokeArgs
{
/// <summary>
/// The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
/// </summary>
[Input("resourceGroupName", required: true)]
public string ResourceGroupName { get; set; } = null!;

/// <summary>
/// The name of the Service resource.
/// </summary>
[Input("serviceName", required: true)]
public string ServiceName { get; set; } = null!;

public GetMonitoringSettingArgs()
{
}
public static new GetMonitoringSettingArgs Empty => new GetMonitoringSettingArgs();
}

public sealed class GetMonitoringSettingInvokeArgs : global::Pulumi.InvokeArgs
{
/// <summary>
/// The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
/// </summary>
[Input("resourceGroupName", required: true)]
public Input<string> ResourceGroupName { get; set; } = null!;

/// <summary>
/// The name of the Service resource.
/// </summary>
[Input("serviceName", required: true)]
public Input<string> ServiceName { get; set; } = null!;

public GetMonitoringSettingInvokeArgs()
{
}
public static new GetMonitoringSettingInvokeArgs Empty => new GetMonitoringSettingInvokeArgs();
}


[OutputType]
public sealed class GetMonitoringSettingResult
{
/// <summary>
/// Fully qualified resource Id for the resource.
/// </summary>
public readonly string Id;
/// <summary>
/// The name of the resource.
/// </summary>
public readonly string Name;
/// <summary>
/// Properties of the Monitoring Setting resource
/// </summary>
public readonly Outputs.MonitoringSettingPropertiesResponse Properties;
/// <summary>
/// The type of the resource.
/// </summary>
public readonly string Type;

[OutputConstructor]
private GetMonitoringSettingResult(
string id,

string name,

Outputs.MonitoringSettingPropertiesResponse properties,

string type)
{
Id = id;
Name = name;
Properties = properties;
Type = type;
}
}
}

0 comments on commit d07f6b2

Please sign in to comment.