selectel.getDedicatedConfigurationV1
Explore with Pulumi AI
Provides a list of server configurations available in Selectel.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as fs from "fs";
import * as selectel from "@pulumi/selectel";
const serverConfig = selectel.getDedicatedConfigurationV1({
projectId: selectel_vpc_project_v2.project_1.id,
deepFilter: fs.readFileSync("filter.json", "utf8"),
});
import pulumi
import pulumi_selectel as selectel
server_config = selectel.get_dedicated_configuration_v1(project_id=selectel_vpc_project_v2["project_1"]["id"],
deep_filter=(lambda path: open(path).read())("filter.json"))
package main
import (
"os"
"github.com/pulumi/pulumi-terraform-provider/sdks/go/selectel/v7/selectel"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func readFileOrPanic(path string) pulumi.StringPtrInput {
data, err := os.ReadFile(path)
if err != nil {
panic(err.Error())
}
return pulumi.String(string(data))
}
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := selectel.GetDedicatedConfigurationV1(ctx, &selectel.GetDedicatedConfigurationV1Args{
ProjectId: selectel_vpc_project_v2.Project_1.Id,
DeepFilter: pulumi.StringRef(readFileOrPanic("filter.json")),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.IO;
using System.Linq;
using Pulumi;
using Selectel = Pulumi.Selectel;
return await Deployment.RunAsync(() =>
{
var serverConfig = Selectel.GetDedicatedConfigurationV1.Invoke(new()
{
ProjectId = selectel_vpc_project_v2.Project_1.Id,
DeepFilter = File.ReadAllText("filter.json"),
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.selectel.SelectelFunctions;
import com.pulumi.selectel.inputs.GetDedicatedConfigurationV1Args;
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) {
final var serverConfig = SelectelFunctions.getDedicatedConfigurationV1(GetDedicatedConfigurationV1Args.builder()
.projectId(selectel_vpc_project_v2.project_1().id())
.deepFilter(Files.readString(Paths.get("filter.json")))
.build());
}
}
variables:
serverConfig:
fn::invoke:
function: selectel:getDedicatedConfigurationV1
arguments:
projectId: ${selectel_vpc_project_v2.project_1.id}
deepFilter:
fn::readFile: filter.json
Using getDedicatedConfigurationV1
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getDedicatedConfigurationV1(args: GetDedicatedConfigurationV1Args, opts?: InvokeOptions): Promise<GetDedicatedConfigurationV1Result>
function getDedicatedConfigurationV1Output(args: GetDedicatedConfigurationV1OutputArgs, opts?: InvokeOptions): Output<GetDedicatedConfigurationV1Result>
def get_dedicated_configuration_v1(deep_filter: Optional[str] = None,
id: Optional[str] = None,
project_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetDedicatedConfigurationV1Result
def get_dedicated_configuration_v1_output(deep_filter: Optional[pulumi.Input[str]] = None,
id: Optional[pulumi.Input[str]] = None,
project_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDedicatedConfigurationV1Result]
func GetDedicatedConfigurationV1(ctx *Context, args *GetDedicatedConfigurationV1Args, opts ...InvokeOption) (*GetDedicatedConfigurationV1Result, error)
func GetDedicatedConfigurationV1Output(ctx *Context, args *GetDedicatedConfigurationV1OutputArgs, opts ...InvokeOption) GetDedicatedConfigurationV1ResultOutput
> Note: This function is named GetDedicatedConfigurationV1
in the Go SDK.
public static class GetDedicatedConfigurationV1
{
public static Task<GetDedicatedConfigurationV1Result> InvokeAsync(GetDedicatedConfigurationV1Args args, InvokeOptions? opts = null)
public static Output<GetDedicatedConfigurationV1Result> Invoke(GetDedicatedConfigurationV1InvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDedicatedConfigurationV1Result> getDedicatedConfigurationV1(GetDedicatedConfigurationV1Args args, InvokeOptions options)
public static Output<GetDedicatedConfigurationV1Result> getDedicatedConfigurationV1(GetDedicatedConfigurationV1Args args, InvokeOptions options)
fn::invoke:
function: selectel:index/getDedicatedConfigurationV1:getDedicatedConfigurationV1
arguments:
# arguments dictionary
The following arguments are supported:
- Project
Id string - Unique identifier of the associated project. Retrieved from the selectel.VpcProjectV2 resource. Learn more about Projects.
- Deep
Filter string JSON filter. You can use it to filter the results. See an example of the filter values in the API documentation. For example, to get configurations with 1 GPU, with the "Active" state, and that are not manually erasable, you can use the following filter:
{ "gpu": { "count": 1 }, "state": "Active", "is_manual_erase": false }
Note: Arrays filter checks inclusion, not the full equality.
- Id string
- Unique identifier of the configuration.
- Project
Id string - Unique identifier of the associated project. Retrieved from the selectel.VpcProjectV2 resource. Learn more about Projects.
- Deep
Filter string JSON filter. You can use it to filter the results. See an example of the filter values in the API documentation. For example, to get configurations with 1 GPU, with the "Active" state, and that are not manually erasable, you can use the following filter:
{ "gpu": { "count": 1 }, "state": "Active", "is_manual_erase": false }
Note: Arrays filter checks inclusion, not the full equality.
- Id string
- Unique identifier of the configuration.
- project
Id String - Unique identifier of the associated project. Retrieved from the selectel.VpcProjectV2 resource. Learn more about Projects.
- deep
Filter String JSON filter. You can use it to filter the results. See an example of the filter values in the API documentation. For example, to get configurations with 1 GPU, with the "Active" state, and that are not manually erasable, you can use the following filter:
{ "gpu": { "count": 1 }, "state": "Active", "is_manual_erase": false }
Note: Arrays filter checks inclusion, not the full equality.
- id String
- Unique identifier of the configuration.
- project
Id string - Unique identifier of the associated project. Retrieved from the selectel.VpcProjectV2 resource. Learn more about Projects.
- deep
Filter string JSON filter. You can use it to filter the results. See an example of the filter values in the API documentation. For example, to get configurations with 1 GPU, with the "Active" state, and that are not manually erasable, you can use the following filter:
{ "gpu": { "count": 1 }, "state": "Active", "is_manual_erase": false }
Note: Arrays filter checks inclusion, not the full equality.
- id string
- Unique identifier of the configuration.
- project_
id str - Unique identifier of the associated project. Retrieved from the selectel.VpcProjectV2 resource. Learn more about Projects.
- deep_
filter str JSON filter. You can use it to filter the results. See an example of the filter values in the API documentation. For example, to get configurations with 1 GPU, with the "Active" state, and that are not manually erasable, you can use the following filter:
{ "gpu": { "count": 1 }, "state": "Active", "is_manual_erase": false }
Note: Arrays filter checks inclusion, not the full equality.
- id str
- Unique identifier of the configuration.
- project
Id String - Unique identifier of the associated project. Retrieved from the selectel.VpcProjectV2 resource. Learn more about Projects.
- deep
Filter String JSON filter. You can use it to filter the results. See an example of the filter values in the API documentation. For example, to get configurations with 1 GPU, with the "Active" state, and that are not manually erasable, you can use the following filter:
{ "gpu": { "count": 1 }, "state": "Active", "is_manual_erase": false }
Note: Arrays filter checks inclusion, not the full equality.
- id String
- Unique identifier of the configuration.
getDedicatedConfigurationV1 Result
The following output properties are available:
- Configurations
List<Get
Dedicated Configuration V1Configuration> - List of the available configurations:
- Id string
- Unique identifier of the configuration.
- Project
Id string - Deep
Filter string
- Configurations
[]Get
Dedicated Configuration V1Configuration - List of the available configurations:
- Id string
- Unique identifier of the configuration.
- Project
Id string - Deep
Filter string
- configurations
List<Get
Dedicated Configuration V1Configuration> - List of the available configurations:
- id String
- Unique identifier of the configuration.
- project
Id String - deep
Filter String
- configurations
Get
Dedicated Configuration V1Configuration[] - List of the available configurations:
- id string
- Unique identifier of the configuration.
- project
Id string - deep
Filter string
- configurations
Sequence[Get
Dedicated Configuration V1Configuration] - List of the available configurations:
- id str
- Unique identifier of the configuration.
- project_
id str - deep_
filter str
- configurations List<Property Map>
- List of the available configurations:
- id String
- Unique identifier of the configuration.
- project
Id String - deep
Filter String
Supporting Types
GetDedicatedConfigurationV1Configuration
Package Details
- Repository
- selectel selectel/terraform-provider-selectel
- License
- Notes
- This Pulumi package is based on the
selectel
Terraform Provider.