GitHub v5.10.0, Jun 2 23
GitHub v5.10.0, Jun 2 23
github.EnterpriseOrganization
Explore with Pulumi AI
This resource allows you to create and manage a GitHub enterprise organization.
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Github = Pulumi.Github;
return await Deployment.RunAsync(() =>
{
var org = new Github.EnterpriseOrganization("org", new()
{
EnterpriseId = data.Github_enterprise.Enterprise.Id,
Description = "Organization created with terraform",
BillingEmail = "jon@winteriscoming.com",
AdminLogins = new[]
{
"jon-snow",
},
});
});
package main
import (
"github.com/pulumi/pulumi-github/sdk/v5/go/github"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := github.NewEnterpriseOrganization(ctx, "org", &github.EnterpriseOrganizationArgs{
EnterpriseId: pulumi.Any(data.Github_enterprise.Enterprise.Id),
Description: pulumi.String("Organization created with terraform"),
BillingEmail: pulumi.String("jon@winteriscoming.com"),
AdminLogins: pulumi.StringArray{
pulumi.String("jon-snow"),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.github.EnterpriseOrganization;
import com.pulumi.github.EnterpriseOrganizationArgs;
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 org = new EnterpriseOrganization("org", EnterpriseOrganizationArgs.builder()
.enterpriseId(data.github_enterprise().enterprise().id())
.description("Organization created with terraform")
.billingEmail("jon@winteriscoming.com")
.adminLogins("jon-snow")
.build());
}
}
import pulumi
import pulumi_github as github
org = github.EnterpriseOrganization("org",
enterprise_id=data["github_enterprise"]["enterprise"]["id"],
description="Organization created with terraform",
billing_email="jon@winteriscoming.com",
admin_logins=["jon-snow"])
import * as pulumi from "@pulumi/pulumi";
import * as github from "@pulumi/github";
const org = new github.EnterpriseOrganization("org", {
enterpriseId: data.github_enterprise.enterprise.id,
description: "Organization created with terraform",
billingEmail: "jon@winteriscoming.com",
adminLogins: ["jon-snow"],
});
resources:
org:
type: github:EnterpriseOrganization
properties:
enterpriseId: ${data.github_enterprise.enterprise.id}
description: Organization created with terraform
billingEmail: jon@winteriscoming.com
adminLogins:
- jon-snow
Create EnterpriseOrganization Resource
new EnterpriseOrganization(name: string, args: EnterpriseOrganizationArgs, opts?: CustomResourceOptions);
@overload
def EnterpriseOrganization(resource_name: str,
opts: Optional[ResourceOptions] = None,
admin_logins: Optional[Sequence[str]] = None,
billing_email: Optional[str] = None,
description: Optional[str] = None,
enterprise_id: Optional[str] = None,
name: Optional[str] = None)
@overload
def EnterpriseOrganization(resource_name: str,
args: EnterpriseOrganizationArgs,
opts: Optional[ResourceOptions] = None)
func NewEnterpriseOrganization(ctx *Context, name string, args EnterpriseOrganizationArgs, opts ...ResourceOption) (*EnterpriseOrganization, error)
public EnterpriseOrganization(string name, EnterpriseOrganizationArgs args, CustomResourceOptions? opts = null)
public EnterpriseOrganization(String name, EnterpriseOrganizationArgs args)
public EnterpriseOrganization(String name, EnterpriseOrganizationArgs args, CustomResourceOptions options)
type: github:EnterpriseOrganization
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EnterpriseOrganizationArgs
- 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 EnterpriseOrganizationArgs
- 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 EnterpriseOrganizationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EnterpriseOrganizationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args EnterpriseOrganizationArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
EnterpriseOrganization Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The EnterpriseOrganization resource accepts the following input properties:
- Admin
Logins List<string> List of organization owner usernames.
- Billing
Email string The billing email address.
- Enterprise
Id string The ID of the enterprise.
- Description string
The description of the organization.
- Name string
The name of the organization.
- Admin
Logins []string List of organization owner usernames.
- Billing
Email string The billing email address.
- Enterprise
Id string The ID of the enterprise.
- Description string
The description of the organization.
- Name string
The name of the organization.
- admin
Logins List<String> List of organization owner usernames.
- billing
Email String The billing email address.
- enterprise
Id String The ID of the enterprise.
- description String
The description of the organization.
- name String
The name of the organization.
- admin
Logins string[] List of organization owner usernames.
- billing
Email string The billing email address.
- enterprise
Id string The ID of the enterprise.
- description string
The description of the organization.
- name string
The name of the organization.
- admin_
logins Sequence[str] List of organization owner usernames.
- billing_
email str The billing email address.
- enterprise_
id str The ID of the enterprise.
- description str
The description of the organization.
- name str
The name of the organization.
- admin
Logins List<String> List of organization owner usernames.
- billing
Email String The billing email address.
- enterprise
Id String The ID of the enterprise.
- description String
The description of the organization.
- name String
The name of the organization.
Outputs
All input properties are implicitly available as output properties. Additionally, the EnterpriseOrganization 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 str
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
Look up Existing EnterpriseOrganization Resource
Get an existing EnterpriseOrganization 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?: EnterpriseOrganizationState, opts?: CustomResourceOptions): EnterpriseOrganization
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
admin_logins: Optional[Sequence[str]] = None,
billing_email: Optional[str] = None,
description: Optional[str] = None,
enterprise_id: Optional[str] = None,
name: Optional[str] = None) -> EnterpriseOrganization
func GetEnterpriseOrganization(ctx *Context, name string, id IDInput, state *EnterpriseOrganizationState, opts ...ResourceOption) (*EnterpriseOrganization, error)
public static EnterpriseOrganization Get(string name, Input<string> id, EnterpriseOrganizationState? state, CustomResourceOptions? opts = null)
public static EnterpriseOrganization get(String name, Output<String> id, EnterpriseOrganizationState 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.
- Admin
Logins List<string> List of organization owner usernames.
- Billing
Email string The billing email address.
- Description string
The description of the organization.
- Enterprise
Id string The ID of the enterprise.
- Name string
The name of the organization.
- Admin
Logins []string List of organization owner usernames.
- Billing
Email string The billing email address.
- Description string
The description of the organization.
- Enterprise
Id string The ID of the enterprise.
- Name string
The name of the organization.
- admin
Logins List<String> List of organization owner usernames.
- billing
Email String The billing email address.
- description String
The description of the organization.
- enterprise
Id String The ID of the enterprise.
- name String
The name of the organization.
- admin
Logins string[] List of organization owner usernames.
- billing
Email string The billing email address.
- description string
The description of the organization.
- enterprise
Id string The ID of the enterprise.
- name string
The name of the organization.
- admin_
logins Sequence[str] List of organization owner usernames.
- billing_
email str The billing email address.
- description str
The description of the organization.
- enterprise_
id str The ID of the enterprise.
- name str
The name of the organization.
- admin
Logins List<String> List of organization owner usernames.
- billing
Email String The billing email address.
- description String
The description of the organization.
- enterprise
Id String The ID of the enterprise.
- name String
The name of the organization.
Import
Support for importing organizations is not currently supported.
Package Details
- Repository
- GitHub pulumi/pulumi-github
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
github
Terraform Provider.