published on Friday, Nov 13, 2026 by cloudfoundry
published on Friday, Nov 13, 2026 by cloudfoundry
Provides a Cloud Foundry resource for binding and unbinding a security group from spaces. Only handles bindings managed through this resource and does not touch the existing space bindings with the security group. On deleting the resource, the security group will be unbound from the mentioned spaces.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as cloudfoundry from "@pulumi/cloudfoundry";
const mySecurityGroupSpaces = new cloudfoundry.SecurityGroupSpaceBindings("my_security_group_spaces", {
securityGroup: "56eedab7-cb97-469b-a3e9-89521827c039",
stagingSpaces: ["02c0cc92-6ecc-44b1-b7b2-096ca19ee143"],
runningSpaces: [
"121c3a95-0f82-45a6-8ff2-1920b2067edb",
"02c0cc92-6ecc-44b1-b7b2-096ca19ee143",
],
});
import pulumi
import pulumi_cloudfoundry as cloudfoundry
my_security_group_spaces = cloudfoundry.SecurityGroupSpaceBindings("my_security_group_spaces",
security_group="56eedab7-cb97-469b-a3e9-89521827c039",
staging_spaces=["02c0cc92-6ecc-44b1-b7b2-096ca19ee143"],
running_spaces=[
"121c3a95-0f82-45a6-8ff2-1920b2067edb",
"02c0cc92-6ecc-44b1-b7b2-096ca19ee143",
])
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/cloudfoundry/cloudfoundry"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cloudfoundry.NewSecurityGroupSpaceBindings(ctx, "my_security_group_spaces", &cloudfoundry.SecurityGroupSpaceBindingsArgs{
SecurityGroup: pulumi.String("56eedab7-cb97-469b-a3e9-89521827c039"),
StagingSpaces: pulumi.StringArray{
pulumi.String("02c0cc92-6ecc-44b1-b7b2-096ca19ee143"),
},
RunningSpaces: pulumi.StringArray{
pulumi.String("121c3a95-0f82-45a6-8ff2-1920b2067edb"),
pulumi.String("02c0cc92-6ecc-44b1-b7b2-096ca19ee143"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Cloudfoundry = Pulumi.Cloudfoundry;
return await Deployment.RunAsync(() =>
{
var mySecurityGroupSpaces = new Cloudfoundry.SecurityGroupSpaceBindings("my_security_group_spaces", new()
{
SecurityGroup = "56eedab7-cb97-469b-a3e9-89521827c039",
StagingSpaces = new[]
{
"02c0cc92-6ecc-44b1-b7b2-096ca19ee143",
},
RunningSpaces = new[]
{
"121c3a95-0f82-45a6-8ff2-1920b2067edb",
"02c0cc92-6ecc-44b1-b7b2-096ca19ee143",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudfoundry.SecurityGroupSpaceBindings;
import com.pulumi.cloudfoundry.SecurityGroupSpaceBindingsArgs;
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 mySecurityGroupSpaces = new SecurityGroupSpaceBindings("mySecurityGroupSpaces", SecurityGroupSpaceBindingsArgs.builder()
.securityGroup("56eedab7-cb97-469b-a3e9-89521827c039")
.stagingSpaces("02c0cc92-6ecc-44b1-b7b2-096ca19ee143")
.runningSpaces(
"121c3a95-0f82-45a6-8ff2-1920b2067edb",
"02c0cc92-6ecc-44b1-b7b2-096ca19ee143")
.build());
}
}
resources:
mySecurityGroupSpaces:
type: cloudfoundry:SecurityGroupSpaceBindings
name: my_security_group_spaces
properties:
securityGroup: 56eedab7-cb97-469b-a3e9-89521827c039
stagingSpaces:
- 02c0cc92-6ecc-44b1-b7b2-096ca19ee143
runningSpaces:
- 121c3a95-0f82-45a6-8ff2-1920b2067edb
- 02c0cc92-6ecc-44b1-b7b2-096ca19ee143
Example coming soon!
Create SecurityGroupSpaceBindings Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new SecurityGroupSpaceBindings(name: string, args: SecurityGroupSpaceBindingsArgs, opts?: CustomResourceOptions);@overload
def SecurityGroupSpaceBindings(resource_name: str,
args: SecurityGroupSpaceBindingsArgs,
opts: Optional[ResourceOptions] = None)
@overload
def SecurityGroupSpaceBindings(resource_name: str,
opts: Optional[ResourceOptions] = None,
security_group: Optional[str] = None,
running_spaces: Optional[Sequence[str]] = None,
staging_spaces: Optional[Sequence[str]] = None)func NewSecurityGroupSpaceBindings(ctx *Context, name string, args SecurityGroupSpaceBindingsArgs, opts ...ResourceOption) (*SecurityGroupSpaceBindings, error)public SecurityGroupSpaceBindings(string name, SecurityGroupSpaceBindingsArgs args, CustomResourceOptions? opts = null)
public SecurityGroupSpaceBindings(String name, SecurityGroupSpaceBindingsArgs args)
public SecurityGroupSpaceBindings(String name, SecurityGroupSpaceBindingsArgs args, CustomResourceOptions options)
type: cloudfoundry:SecurityGroupSpaceBindings
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "cloudfoundry_security_group_space_bindings" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args SecurityGroupSpaceBindingsArgs
- 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 SecurityGroupSpaceBindingsArgs
- 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 SecurityGroupSpaceBindingsArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SecurityGroupSpaceBindingsArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SecurityGroupSpaceBindingsArgs
- 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 securityGroupSpaceBindingsResource = new Cloudfoundry.SecurityGroupSpaceBindings("securityGroupSpaceBindingsResource", new()
{
SecurityGroup = "string",
RunningSpaces = new[]
{
"string",
},
StagingSpaces = new[]
{
"string",
},
});
example, err := cloudfoundry.NewSecurityGroupSpaceBindings(ctx, "securityGroupSpaceBindingsResource", &cloudfoundry.SecurityGroupSpaceBindingsArgs{
SecurityGroup: pulumi.String("string"),
RunningSpaces: pulumi.StringArray{
pulumi.String("string"),
},
StagingSpaces: pulumi.StringArray{
pulumi.String("string"),
},
})
resource "cloudfoundry_security_group_space_bindings" "securityGroupSpaceBindingsResource" {
lifecycle {
create_before_destroy = true
}
security_group = "string"
running_spaces = ["string"]
staging_spaces = ["string"]
}
var securityGroupSpaceBindingsResource = new SecurityGroupSpaceBindings("securityGroupSpaceBindingsResource", SecurityGroupSpaceBindingsArgs.builder()
.securityGroup("string")
.runningSpaces("string")
.stagingSpaces("string")
.build());
security_group_space_bindings_resource = cloudfoundry.SecurityGroupSpaceBindings("securityGroupSpaceBindingsResource",
security_group="string",
running_spaces=["string"],
staging_spaces=["string"])
const securityGroupSpaceBindingsResource = new cloudfoundry.SecurityGroupSpaceBindings("securityGroupSpaceBindingsResource", {
securityGroup: "string",
runningSpaces: ["string"],
stagingSpaces: ["string"],
});
type: cloudfoundry:SecurityGroupSpaceBindings
properties:
runningSpaces:
- string
securityGroup: string
stagingSpaces:
- string
SecurityGroupSpaceBindings 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 SecurityGroupSpaceBindings resource accepts the following input properties:
- Security
Group string - GUID of the isolation segment
- Running
Spaces List<string> - The spaces where the security_group is applied to applications during runtime
- Staging
Spaces List<string> - The spaces where the security_group is applied to applications during staging
- Security
Group string - GUID of the isolation segment
- Running
Spaces []string - The spaces where the security_group is applied to applications during runtime
- Staging
Spaces []string - The spaces where the security_group is applied to applications during staging
- security_
group string - GUID of the isolation segment
- running_
spaces list(string) - The spaces where the security_group is applied to applications during runtime
- staging_
spaces list(string) - The spaces where the security_group is applied to applications during staging
- security
Group String - GUID of the isolation segment
- running
Spaces List<String> - The spaces where the security_group is applied to applications during runtime
- staging
Spaces List<String> - The spaces where the security_group is applied to applications during staging
- security
Group string - GUID of the isolation segment
- running
Spaces string[] - The spaces where the security_group is applied to applications during runtime
- staging
Spaces string[] - The spaces where the security_group is applied to applications during staging
- security_
group str - GUID of the isolation segment
- running_
spaces Sequence[str] - The spaces where the security_group is applied to applications during runtime
- staging_
spaces Sequence[str] - The spaces where the security_group is applied to applications during staging
- security
Group String - GUID of the isolation segment
- running
Spaces List<String> - The spaces where the security_group is applied to applications during runtime
- staging
Spaces List<String> - The spaces where the security_group is applied to applications during staging
Outputs
All input properties are implicitly available as output properties. Additionally, the SecurityGroupSpaceBindings resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing SecurityGroupSpaceBindings Resource
Get an existing SecurityGroupSpaceBindings 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?: SecurityGroupSpaceBindingsState, opts?: CustomResourceOptions): SecurityGroupSpaceBindings@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
running_spaces: Optional[Sequence[str]] = None,
security_group: Optional[str] = None,
staging_spaces: Optional[Sequence[str]] = None) -> SecurityGroupSpaceBindingsfunc GetSecurityGroupSpaceBindings(ctx *Context, name string, id IDInput, state *SecurityGroupSpaceBindingsState, opts ...ResourceOption) (*SecurityGroupSpaceBindings, error)public static SecurityGroupSpaceBindings Get(string name, Input<string> id, SecurityGroupSpaceBindingsState? state, CustomResourceOptions? opts = null)public static SecurityGroupSpaceBindings get(String name, Output<String> id, SecurityGroupSpaceBindingsState state, CustomResourceOptions options)resources: existingSecurityGroupSpaceBindings: type: cloudfoundry:SecurityGroupSpaceBindings get: id: ${id}import {
to = cloudfoundry_security_group_space_bindings.example
id = "${id}"
}
- name string
- The unique name of the resulting resource.
- id Input<ID>
- The unique provider ID of the resource to look up.
- state SecurityGroupSpaceBindingsState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resulting resource.
- id str
- The unique provider ID of the resource to look up.
- 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 resulting resource.
- id IDInput
- The unique provider ID of the resource to look up.
- state SecurityGroupSpaceBindingsState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resulting resource.
- id Input<string>
- The unique provider ID of the resource to look up.
- state SecurityGroupSpaceBindingsState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resulting resource.
- id Output<String>
- The unique provider ID of the resource to look up.
- state SecurityGroupSpaceBindingsState
- Known property values the provider needs, along with the ID, to find the resource. Usually not required.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
- Running
Spaces List<string> - The spaces where the security_group is applied to applications during runtime
- Security
Group string - GUID of the isolation segment
- Staging
Spaces List<string> - The spaces where the security_group is applied to applications during staging
- Running
Spaces []string - The spaces where the security_group is applied to applications during runtime
- Security
Group string - GUID of the isolation segment
- Staging
Spaces []string - The spaces where the security_group is applied to applications during staging
- running_
spaces list(string) - The spaces where the security_group is applied to applications during runtime
- security_
group string - GUID of the isolation segment
- staging_
spaces list(string) - The spaces where the security_group is applied to applications during staging
- running
Spaces List<String> - The spaces where the security_group is applied to applications during runtime
- security
Group String - GUID of the isolation segment
- staging
Spaces List<String> - The spaces where the security_group is applied to applications during staging
- running
Spaces string[] - The spaces where the security_group is applied to applications during runtime
- security
Group string - GUID of the isolation segment
- staging
Spaces string[] - The spaces where the security_group is applied to applications during staging
- running_
spaces Sequence[str] - The spaces where the security_group is applied to applications during runtime
- security_
group str - GUID of the isolation segment
- staging_
spaces Sequence[str] - The spaces where the security_group is applied to applications during staging
- running
Spaces List<String> - The spaces where the security_group is applied to applications during runtime
- security
Group String - GUID of the isolation segment
- staging
Spaces List<String> - The spaces where the security_group is applied to applications during staging
Package Details
- Repository
- cloudfoundry cloudfoundry/terraform-provider-cloudfoundry
- License
- Notes
- This Pulumi package is based on the
cloudfoundryTerraform Provider.
published on Friday, Nov 13, 2026 by cloudfoundry