scaleway.FunctionNamespace
Explore with Pulumi AI
The scaleway.FunctionNamespace
resource allows you to
for Scaleway Serverless Functions.
Refer to the Functions namespace documentation and API documentation for more information.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as scaleway from "@pulumiverse/scaleway";
const main = new scaleway.FunctionNamespace("main", {
name: "main-function-namespace",
description: "Main function namespace",
});
import pulumi
import pulumiverse_scaleway as scaleway
main = scaleway.FunctionNamespace("main",
name="main-function-namespace",
description="Main function namespace")
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-scaleway/sdk/go/scaleway"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := scaleway.NewFunctionNamespace(ctx, "main", &scaleway.FunctionNamespaceArgs{
Name: pulumi.String("main-function-namespace"),
Description: pulumi.String("Main function namespace"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Scaleway = Pulumiverse.Scaleway;
return await Deployment.RunAsync(() =>
{
var main = new Scaleway.FunctionNamespace("main", new()
{
Name = "main-function-namespace",
Description = "Main function namespace",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.scaleway.FunctionNamespace;
import com.pulumi.scaleway.FunctionNamespaceArgs;
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 main = new FunctionNamespace("main", FunctionNamespaceArgs.builder()
.name("main-function-namespace")
.description("Main function namespace")
.build());
}
}
resources:
main:
type: scaleway:FunctionNamespace
properties:
name: main-function-namespace
description: Main function namespace
Create FunctionNamespace Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new FunctionNamespace(name: string, args?: FunctionNamespaceArgs, opts?: CustomResourceOptions);
@overload
def FunctionNamespace(resource_name: str,
args: Optional[FunctionNamespaceArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def FunctionNamespace(resource_name: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
environment_variables: Optional[Mapping[str, str]] = None,
name: Optional[str] = None,
project_id: Optional[str] = None,
region: Optional[str] = None,
secret_environment_variables: Optional[Mapping[str, str]] = None)
func NewFunctionNamespace(ctx *Context, name string, args *FunctionNamespaceArgs, opts ...ResourceOption) (*FunctionNamespace, error)
public FunctionNamespace(string name, FunctionNamespaceArgs? args = null, CustomResourceOptions? opts = null)
public FunctionNamespace(String name, FunctionNamespaceArgs args)
public FunctionNamespace(String name, FunctionNamespaceArgs args, CustomResourceOptions options)
type: scaleway:FunctionNamespace
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args FunctionNamespaceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args FunctionNamespaceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args FunctionNamespaceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args FunctionNamespaceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args FunctionNamespaceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var functionNamespaceResource = new Scaleway.FunctionNamespace("functionNamespaceResource", new()
{
Description = "string",
EnvironmentVariables =
{
{ "string", "string" },
},
Name = "string",
ProjectId = "string",
Region = "string",
SecretEnvironmentVariables =
{
{ "string", "string" },
},
});
example, err := scaleway.NewFunctionNamespace(ctx, "functionNamespaceResource", &scaleway.FunctionNamespaceArgs{
Description: pulumi.String("string"),
EnvironmentVariables: pulumi.StringMap{
"string": pulumi.String("string"),
},
Name: pulumi.String("string"),
ProjectId: pulumi.String("string"),
Region: pulumi.String("string"),
SecretEnvironmentVariables: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var functionNamespaceResource = new FunctionNamespace("functionNamespaceResource", FunctionNamespaceArgs.builder()
.description("string")
.environmentVariables(Map.of("string", "string"))
.name("string")
.projectId("string")
.region("string")
.secretEnvironmentVariables(Map.of("string", "string"))
.build());
function_namespace_resource = scaleway.FunctionNamespace("functionNamespaceResource",
description="string",
environment_variables={
"string": "string",
},
name="string",
project_id="string",
region="string",
secret_environment_variables={
"string": "string",
})
const functionNamespaceResource = new scaleway.FunctionNamespace("functionNamespaceResource", {
description: "string",
environmentVariables: {
string: "string",
},
name: "string",
projectId: "string",
region: "string",
secretEnvironmentVariables: {
string: "string",
},
});
type: scaleway:FunctionNamespace
properties:
description: string
environmentVariables:
string: string
name: string
projectId: string
region: string
secretEnvironmentVariables:
string: string
FunctionNamespace Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The FunctionNamespace resource accepts the following input properties:
- Description string
- The description of the namespace.
- Environment
Variables Dictionary<string, string> - The environment variables of the namespace.
- Name string
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- Project
Id string project_id
) The unique identifier of the project that contains the namespace.- Region string
region
). The region in which the namespace is created.- Secret
Environment Dictionary<string, string>Variables - The secret environment variables of the namespace.
- Description string
- The description of the namespace.
- Environment
Variables map[string]string - The environment variables of the namespace.
- Name string
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- Project
Id string project_id
) The unique identifier of the project that contains the namespace.- Region string
region
). The region in which the namespace is created.- Secret
Environment map[string]stringVariables - The secret environment variables of the namespace.
- description String
- The description of the namespace.
- environment
Variables Map<String,String> - The environment variables of the namespace.
- name String
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- project
Id String project_id
) The unique identifier of the project that contains the namespace.- region String
region
). The region in which the namespace is created.- secret
Environment Map<String,String>Variables - The secret environment variables of the namespace.
- description string
- The description of the namespace.
- environment
Variables {[key: string]: string} - The environment variables of the namespace.
- name string
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- project
Id string project_id
) The unique identifier of the project that contains the namespace.- region string
region
). The region in which the namespace is created.- secret
Environment {[key: string]: string}Variables - The secret environment variables of the namespace.
- description str
- The description of the namespace.
- environment_
variables Mapping[str, str] - The environment variables of the namespace.
- name str
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- project_
id str project_id
) The unique identifier of the project that contains the namespace.- region str
region
). The region in which the namespace is created.- secret_
environment_ Mapping[str, str]variables - The secret environment variables of the namespace.
- description String
- The description of the namespace.
- environment
Variables Map<String> - The environment variables of the namespace.
- name String
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- project
Id String project_id
) The unique identifier of the project that contains the namespace.- region String
region
). The region in which the namespace is created.- secret
Environment Map<String>Variables - The secret environment variables of the namespace.
Outputs
All input properties are implicitly available as output properties. Additionally, the FunctionNamespace resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Organization
Id string - The Organization ID with which the namespace is associated.
- Registry
Endpoint string - The registry endpoint of the namespace.
- Registry
Namespace stringId - The registry namespace ID of the namespace.
- Id string
- The provider-assigned unique ID for this managed resource.
- Organization
Id string - The Organization ID with which the namespace is associated.
- Registry
Endpoint string - The registry endpoint of the namespace.
- Registry
Namespace stringId - The registry namespace ID of the namespace.
- id String
- The provider-assigned unique ID for this managed resource.
- organization
Id String - The Organization ID with which the namespace is associated.
- registry
Endpoint String - The registry endpoint of the namespace.
- registry
Namespace StringId - The registry namespace ID of the namespace.
- id string
- The provider-assigned unique ID for this managed resource.
- organization
Id string - The Organization ID with which the namespace is associated.
- registry
Endpoint string - The registry endpoint of the namespace.
- registry
Namespace stringId - The registry namespace ID of the namespace.
- id str
- The provider-assigned unique ID for this managed resource.
- organization_
id str - The Organization ID with which the namespace is associated.
- registry_
endpoint str - The registry endpoint of the namespace.
- registry_
namespace_ strid - The registry namespace ID of the namespace.
- id String
- The provider-assigned unique ID for this managed resource.
- organization
Id String - The Organization ID with which the namespace is associated.
- registry
Endpoint String - The registry endpoint of the namespace.
- registry
Namespace StringId - The registry namespace ID of the namespace.
Look up Existing FunctionNamespace Resource
Get an existing FunctionNamespace resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: FunctionNamespaceState, opts?: CustomResourceOptions): FunctionNamespace
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
environment_variables: Optional[Mapping[str, str]] = None,
name: Optional[str] = None,
organization_id: Optional[str] = None,
project_id: Optional[str] = None,
region: Optional[str] = None,
registry_endpoint: Optional[str] = None,
registry_namespace_id: Optional[str] = None,
secret_environment_variables: Optional[Mapping[str, str]] = None) -> FunctionNamespace
func GetFunctionNamespace(ctx *Context, name string, id IDInput, state *FunctionNamespaceState, opts ...ResourceOption) (*FunctionNamespace, error)
public static FunctionNamespace Get(string name, Input<string> id, FunctionNamespaceState? state, CustomResourceOptions? opts = null)
public static FunctionNamespace get(String name, Output<String> id, FunctionNamespaceState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Description string
- The description of the namespace.
- Environment
Variables Dictionary<string, string> - The environment variables of the namespace.
- Name string
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- Organization
Id string - The Organization ID with which the namespace is associated.
- Project
Id string project_id
) The unique identifier of the project that contains the namespace.- Region string
region
). The region in which the namespace is created.- Registry
Endpoint string - The registry endpoint of the namespace.
- Registry
Namespace stringId - The registry namespace ID of the namespace.
- Secret
Environment Dictionary<string, string>Variables - The secret environment variables of the namespace.
- Description string
- The description of the namespace.
- Environment
Variables map[string]string - The environment variables of the namespace.
- Name string
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- Organization
Id string - The Organization ID with which the namespace is associated.
- Project
Id string project_id
) The unique identifier of the project that contains the namespace.- Region string
region
). The region in which the namespace is created.- Registry
Endpoint string - The registry endpoint of the namespace.
- Registry
Namespace stringId - The registry namespace ID of the namespace.
- Secret
Environment map[string]stringVariables - The secret environment variables of the namespace.
- description String
- The description of the namespace.
- environment
Variables Map<String,String> - The environment variables of the namespace.
- name String
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- organization
Id String - The Organization ID with which the namespace is associated.
- project
Id String project_id
) The unique identifier of the project that contains the namespace.- region String
region
). The region in which the namespace is created.- registry
Endpoint String - The registry endpoint of the namespace.
- registry
Namespace StringId - The registry namespace ID of the namespace.
- secret
Environment Map<String,String>Variables - The secret environment variables of the namespace.
- description string
- The description of the namespace.
- environment
Variables {[key: string]: string} - The environment variables of the namespace.
- name string
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- organization
Id string - The Organization ID with which the namespace is associated.
- project
Id string project_id
) The unique identifier of the project that contains the namespace.- region string
region
). The region in which the namespace is created.- registry
Endpoint string - The registry endpoint of the namespace.
- registry
Namespace stringId - The registry namespace ID of the namespace.
- secret
Environment {[key: string]: string}Variables - The secret environment variables of the namespace.
- description str
- The description of the namespace.
- environment_
variables Mapping[str, str] - The environment variables of the namespace.
- name str
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- organization_
id str - The Organization ID with which the namespace is associated.
- project_
id str project_id
) The unique identifier of the project that contains the namespace.- region str
region
). The region in which the namespace is created.- registry_
endpoint str - The registry endpoint of the namespace.
- registry_
namespace_ strid - The registry namespace ID of the namespace.
- secret_
environment_ Mapping[str, str]variables - The secret environment variables of the namespace.
- description String
- The description of the namespace.
- environment
Variables Map<String> - The environment variables of the namespace.
- name String
The unique name of the Functions namespace.
Important Updates to the
name
argument will recreate the namespace.- organization
Id String - The Organization ID with which the namespace is associated.
- project
Id String project_id
) The unique identifier of the project that contains the namespace.- region String
region
). The region in which the namespace is created.- registry
Endpoint String - The registry endpoint of the namespace.
- registry
Namespace StringId - The registry namespace ID of the namespace.
- secret
Environment Map<String>Variables - The secret environment variables of the namespace.
Import
Functions namespaces can be imported using {region}/{id}
, as shown below:
bash
$ pulumi import scaleway:index/functionNamespace:FunctionNamespace main fr-par/11111111-1111-1111-1111-111111111111
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- scaleway pulumiverse/pulumi-scaleway
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
scaleway
Terraform Provider.