scaleway.elasticmetal.getPartitionSchema
Explore with Pulumi AI
The scaleway.elasticmetal.getPartitionSchema data source allows you to retrieve a ready-to-use partitioning schema for a BareMetal server. This schema can be used for custom installations with optional swap and extra partitions.
This data source simplifies the process of generating valid partitioning configurations, especially useful when dealing with OS and offer compatibility requirements.
Partitioning Details
The partitioning schema generated by the scaleway.elasticmetal.getPartitionSchema
data source includes a root (/
) partition that is 20GB in size by default.
If additional storage is required, you can enable the extra_partition
option to mount extra space on a custom path (e.g., /data
).
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as scaleway from "@pulumi/scaleway";
const _default = scaleway.elasticmetal.getPartitionSchema({
offerId: "11111111-1111-1111-1111-111111111111",
osId: "22222222-2222-2222-2222-222222222222",
swap: true,
extraPartition: true,
ext4Mountpoint: "/data",
});
import pulumi
import pulumi_scaleway as scaleway
default = scaleway.elasticmetal.get_partition_schema(offer_id="11111111-1111-1111-1111-111111111111",
os_id="22222222-2222-2222-2222-222222222222",
swap=True,
extra_partition=True,
ext4_mountpoint="/data")
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway/elasticmetal"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := elasticmetal.GetPartitionSchema(ctx, &elasticmetal.GetPartitionSchemaArgs{
OfferId: "11111111-1111-1111-1111-111111111111",
OsId: "22222222-2222-2222-2222-222222222222",
Swap: pulumi.BoolRef(true),
ExtraPartition: pulumi.BoolRef(true),
Ext4Mountpoint: pulumi.StringRef("/data"),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Scaleway = Pulumi.Scaleway;
return await Deployment.RunAsync(() =>
{
var @default = Scaleway.Elasticmetal.GetPartitionSchema.Invoke(new()
{
OfferId = "11111111-1111-1111-1111-111111111111",
OsId = "22222222-2222-2222-2222-222222222222",
Swap = true,
ExtraPartition = true,
Ext4Mountpoint = "/data",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.scaleway.elasticmetal.ElasticmetalFunctions;
import com.pulumi.scaleway.elasticmetal.inputs.GetPartitionSchemaArgs;
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 default = ElasticmetalFunctions.getPartitionSchema(GetPartitionSchemaArgs.builder()
.offerId("11111111-1111-1111-1111-111111111111")
.osId("22222222-2222-2222-2222-222222222222")
.swap(true)
.extraPartition(true)
.ext4Mountpoint("/data")
.build());
}
}
variables:
default:
fn::invoke:
function: scaleway:elasticmetal:getPartitionSchema
arguments:
offerId: 11111111-1111-1111-1111-111111111111
osId: 22222222-2222-2222-2222-222222222222
swap: true
extraPartition: true
ext4Mountpoint: /data
Using getPartitionSchema
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 getPartitionSchema(args: GetPartitionSchemaArgs, opts?: InvokeOptions): Promise<GetPartitionSchemaResult>
function getPartitionSchemaOutput(args: GetPartitionSchemaOutputArgs, opts?: InvokeOptions): Output<GetPartitionSchemaResult>
def get_partition_schema(ext4_mountpoint: Optional[str] = None,
extra_partition: Optional[bool] = None,
offer_id: Optional[str] = None,
os_id: Optional[str] = None,
swap: Optional[bool] = None,
opts: Optional[InvokeOptions] = None) -> GetPartitionSchemaResult
def get_partition_schema_output(ext4_mountpoint: Optional[pulumi.Input[str]] = None,
extra_partition: Optional[pulumi.Input[bool]] = None,
offer_id: Optional[pulumi.Input[str]] = None,
os_id: Optional[pulumi.Input[str]] = None,
swap: Optional[pulumi.Input[bool]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPartitionSchemaResult]
func GetPartitionSchema(ctx *Context, args *GetPartitionSchemaArgs, opts ...InvokeOption) (*GetPartitionSchemaResult, error)
func GetPartitionSchemaOutput(ctx *Context, args *GetPartitionSchemaOutputArgs, opts ...InvokeOption) GetPartitionSchemaResultOutput
> Note: This function is named GetPartitionSchema
in the Go SDK.
public static class GetPartitionSchema
{
public static Task<GetPartitionSchemaResult> InvokeAsync(GetPartitionSchemaArgs args, InvokeOptions? opts = null)
public static Output<GetPartitionSchemaResult> Invoke(GetPartitionSchemaInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetPartitionSchemaResult> getPartitionSchema(GetPartitionSchemaArgs args, InvokeOptions options)
public static Output<GetPartitionSchemaResult> getPartitionSchema(GetPartitionSchemaArgs args, InvokeOptions options)
fn::invoke:
function: scaleway:elasticmetal/getPartitionSchema:getPartitionSchema
arguments:
# arguments dictionary
The following arguments are supported:
- Offer
Id string - The UUID of the BareMetal offer.
- Os
Id string - The UUID of the OS image.
- Ext4Mountpoint string
- The mount point for the extra partition. Must be an absolute path using alphanumeric characters and underscores.
- Extra
Partition bool - Whether to add an extra ext4 data partition.
- Swap bool
- Whether to include a swap partition.
- Offer
Id string - The UUID of the BareMetal offer.
- Os
Id string - The UUID of the OS image.
- Ext4Mountpoint string
- The mount point for the extra partition. Must be an absolute path using alphanumeric characters and underscores.
- Extra
Partition bool - Whether to add an extra ext4 data partition.
- Swap bool
- Whether to include a swap partition.
- offer
Id String - The UUID of the BareMetal offer.
- os
Id String - The UUID of the OS image.
- ext4Mountpoint String
- The mount point for the extra partition. Must be an absolute path using alphanumeric characters and underscores.
- extra
Partition Boolean - Whether to add an extra ext4 data partition.
- swap Boolean
- Whether to include a swap partition.
- offer
Id string - The UUID of the BareMetal offer.
- os
Id string - The UUID of the OS image.
- ext4Mountpoint string
- The mount point for the extra partition. Must be an absolute path using alphanumeric characters and underscores.
- extra
Partition boolean - Whether to add an extra ext4 data partition.
- swap boolean
- Whether to include a swap partition.
- offer_
id str - The UUID of the BareMetal offer.
- os_
id str - The UUID of the OS image.
- ext4_
mountpoint str - The mount point for the extra partition. Must be an absolute path using alphanumeric characters and underscores.
- extra_
partition bool - Whether to add an extra ext4 data partition.
- swap bool
- Whether to include a swap partition.
- offer
Id String - The UUID of the BareMetal offer.
- os
Id String - The UUID of the OS image.
- ext4Mountpoint String
- The mount point for the extra partition. Must be an absolute path using alphanumeric characters and underscores.
- extra
Partition Boolean - Whether to add an extra ext4 data partition.
- swap Boolean
- Whether to include a swap partition.
getPartitionSchema Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Json
Partition string - — A validated partitioning schema in JSON format that can be directly used for BareMetal server deployment.
- Offer
Id string - Os
Id string - Ext4Mountpoint string
- Extra
Partition bool - Swap bool
- Id string
- The provider-assigned unique ID for this managed resource.
- Json
Partition string - — A validated partitioning schema in JSON format that can be directly used for BareMetal server deployment.
- Offer
Id string - Os
Id string - Ext4Mountpoint string
- Extra
Partition bool - Swap bool
- id String
- The provider-assigned unique ID for this managed resource.
- json
Partition String - — A validated partitioning schema in JSON format that can be directly used for BareMetal server deployment.
- offer
Id String - os
Id String - ext4Mountpoint String
- extra
Partition Boolean - swap Boolean
- id string
- The provider-assigned unique ID for this managed resource.
- json
Partition string - — A validated partitioning schema in JSON format that can be directly used for BareMetal server deployment.
- offer
Id string - os
Id string - ext4Mountpoint string
- extra
Partition boolean - swap boolean
- id str
- The provider-assigned unique ID for this managed resource.
- json_
partition str - — A validated partitioning schema in JSON format that can be directly used for BareMetal server deployment.
- offer_
id str - os_
id str - ext4_
mountpoint str - extra_
partition bool - swap bool
- id String
- The provider-assigned unique ID for this managed resource.
- json
Partition String - — A validated partitioning schema in JSON format that can be directly used for BareMetal server deployment.
- offer
Id String - os
Id String - ext4Mountpoint String
- extra
Partition Boolean - swap Boolean
Package Details
- Repository
- scaleway pulumiverse/pulumi-scaleway
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
scaleway
Terraform Provider.