Manages a GitHub connector in Dex. This connector allows users to authenticate using their GitHub accounts and supports organization and team-based access control.
Create GitHubConnector Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new GitHubConnector(name: string, args: GitHubConnectorArgs, opts?: CustomResourceOptions);@overload
def GitHubConnector(resource_name: str,
args: GitHubConnectorArgs,
opts: Optional[ResourceOptions] = None)
@overload
def GitHubConnector(resource_name: str,
opts: Optional[ResourceOptions] = None,
client_id: Optional[str] = None,
client_secret: Optional[str] = None,
connector_id: Optional[str] = None,
name: Optional[str] = None,
redirect_uri: Optional[str] = None,
host_name: Optional[str] = None,
load_all_groups: Optional[bool] = None,
orgs: Optional[Sequence[GitHubOrgArgs]] = None,
preferred_email_domain: Optional[str] = None,
root_ca: Optional[str] = None,
team_name_field: Optional[str] = None,
use_login_as_id: Optional[bool] = None)func NewGitHubConnector(ctx *Context, name string, args GitHubConnectorArgs, opts ...ResourceOption) (*GitHubConnector, error)public GitHubConnector(string name, GitHubConnectorArgs args, CustomResourceOptions? opts = null)
public GitHubConnector(String name, GitHubConnectorArgs args)
public GitHubConnector(String name, GitHubConnectorArgs args, CustomResourceOptions options)
type: dex:resources:GitHubConnector
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 GitHubConnectorArgs
- 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 GitHubConnectorArgs
- 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 GitHubConnectorArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args GitHubConnectorArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args GitHubConnectorArgs
- 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 gitHubConnectorResource = new Dex.Resources.GitHubConnector("gitHubConnectorResource", new()
{
ClientId = "string",
ClientSecret = "string",
ConnectorId = "string",
Name = "string",
RedirectUri = "string",
HostName = "string",
LoadAllGroups = false,
Orgs = new[]
{
new Dex.Resources.Inputs.GitHubOrgArgs
{
Name = "string",
Teams = new[]
{
"string",
},
},
},
PreferredEmailDomain = "string",
RootCA = "string",
TeamNameField = "string",
UseLoginAsID = false,
});
example, err := resources.NewGitHubConnector(ctx, "gitHubConnectorResource", &resources.GitHubConnectorArgs{
ClientId: pulumi.String("string"),
ClientSecret: pulumi.String("string"),
ConnectorId: pulumi.String("string"),
Name: pulumi.String("string"),
RedirectUri: pulumi.String("string"),
HostName: pulumi.String("string"),
LoadAllGroups: pulumi.Bool(false),
Orgs: resources.GitHubOrgArray{
&resources.GitHubOrgArgs{
Name: pulumi.String("string"),
Teams: pulumi.StringArray{
pulumi.String("string"),
},
},
},
PreferredEmailDomain: pulumi.String("string"),
RootCA: pulumi.String("string"),
TeamNameField: pulumi.String("string"),
UseLoginAsID: pulumi.Bool(false),
})
var gitHubConnectorResource = new GitHubConnector("gitHubConnectorResource", GitHubConnectorArgs.builder()
.clientId("string")
.clientSecret("string")
.connectorId("string")
.name("string")
.redirectUri("string")
.hostName("string")
.loadAllGroups(false)
.orgs(GitHubOrgArgs.builder()
.name("string")
.teams("string")
.build())
.preferredEmailDomain("string")
.rootCA("string")
.teamNameField("string")
.useLoginAsID(false)
.build());
git_hub_connector_resource = dex.resources.GitHubConnector("gitHubConnectorResource",
client_id="string",
client_secret="string",
connector_id="string",
name="string",
redirect_uri="string",
host_name="string",
load_all_groups=False,
orgs=[{
"name": "string",
"teams": ["string"],
}],
preferred_email_domain="string",
root_ca="string",
team_name_field="string",
use_login_as_id=False)
const gitHubConnectorResource = new dex.resources.GitHubConnector("gitHubConnectorResource", {
clientId: "string",
clientSecret: "string",
connectorId: "string",
name: "string",
redirectUri: "string",
hostName: "string",
loadAllGroups: false,
orgs: [{
name: "string",
teams: ["string"],
}],
preferredEmailDomain: "string",
rootCA: "string",
teamNameField: "string",
useLoginAsID: false,
});
type: dex:resources:GitHubConnector
properties:
clientId: string
clientSecret: string
connectorId: string
hostName: string
loadAllGroups: false
name: string
orgs:
- name: string
teams:
- string
preferredEmailDomain: string
redirectUri: string
rootCA: string
teamNameField: string
useLoginAsID: false
GitHubConnector 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 GitHubConnector resource accepts the following input properties:
- Client
Id string - GitHub OAuth app client ID.
- Client
Secret string - GitHub OAuth app client secret.
- Connector
Id string - Unique identifier for the GitHub connector.
- Name string
- Human-readable name for the connector, displayed to users during login.
- Redirect
Uri string - Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
- Host
Name string - GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
- Load
All boolGroups - If true, load all groups (teams) the user is a member of. Defaults to false.
- Orgs
List<Git
Hub Org> - List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
- Preferred
Email stringDomain - Preferred email domain. If set, users with emails in this domain will be preferred.
- Root
CA string - Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
- Team
Name stringField - Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
- Use
Login boolAs ID - If true, use GitHub login username as the user ID. Defaults to false.
- Client
Id string - GitHub OAuth app client ID.
- Client
Secret string - GitHub OAuth app client secret.
- Connector
Id string - Unique identifier for the GitHub connector.
- Name string
- Human-readable name for the connector, displayed to users during login.
- Redirect
Uri string - Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
- Host
Name string - GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
- Load
All boolGroups - If true, load all groups (teams) the user is a member of. Defaults to false.
- Orgs
[]Git
Hub Org Args - List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
- Preferred
Email stringDomain - Preferred email domain. If set, users with emails in this domain will be preferred.
- Root
CA string - Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
- Team
Name stringField - Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
- Use
Login boolAs ID - If true, use GitHub login username as the user ID. Defaults to false.
- client
Id String - GitHub OAuth app client ID.
- client
Secret String - GitHub OAuth app client secret.
- connector
Id String - Unique identifier for the GitHub connector.
- name String
- Human-readable name for the connector, displayed to users during login.
- redirect
Uri String - Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
- host
Name String - GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
- load
All BooleanGroups - If true, load all groups (teams) the user is a member of. Defaults to false.
- orgs
List<Git
Hub Org> - List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
- preferred
Email StringDomain - Preferred email domain. If set, users with emails in this domain will be preferred.
- root
CA String - Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
- team
Name StringField - Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
- use
Login BooleanAs ID - If true, use GitHub login username as the user ID. Defaults to false.
- client
Id string - GitHub OAuth app client ID.
- client
Secret string - GitHub OAuth app client secret.
- connector
Id string - Unique identifier for the GitHub connector.
- name string
- Human-readable name for the connector, displayed to users during login.
- redirect
Uri string - Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
- host
Name string - GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
- load
All booleanGroups - If true, load all groups (teams) the user is a member of. Defaults to false.
- orgs
Git
Hub Org[] - List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
- preferred
Email stringDomain - Preferred email domain. If set, users with emails in this domain will be preferred.
- root
CA string - Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
- team
Name stringField - Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
- use
Login booleanAs ID - If true, use GitHub login username as the user ID. Defaults to false.
- client_
id str - GitHub OAuth app client ID.
- client_
secret str - GitHub OAuth app client secret.
- connector_
id str - Unique identifier for the GitHub connector.
- name str
- Human-readable name for the connector, displayed to users during login.
- redirect_
uri str - Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
- host_
name str - GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
- load_
all_ boolgroups - If true, load all groups (teams) the user is a member of. Defaults to false.
- orgs
Sequence[Git
Hub Org Args] - List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
- preferred_
email_ strdomain - Preferred email domain. If set, users with emails in this domain will be preferred.
- root_
ca str - Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
- team_
name_ strfield - Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
- use_
login_ boolas_ id - If true, use GitHub login username as the user ID. Defaults to false.
- client
Id String - GitHub OAuth app client ID.
- client
Secret String - GitHub OAuth app client secret.
- connector
Id String - Unique identifier for the GitHub connector.
- name String
- Human-readable name for the connector, displayed to users during login.
- redirect
Uri String - Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
- host
Name String - GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
- load
All BooleanGroups - If true, load all groups (teams) the user is a member of. Defaults to false.
- orgs List<Property Map>
- List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
- preferred
Email StringDomain - Preferred email domain. If set, users with emails in this domain will be preferred.
- root
CA String - Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
- team
Name StringField - Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
- use
Login BooleanAs ID - If true, use GitHub login username as the user ID. Defaults to false.
Outputs
All input properties are implicitly available as output properties. Additionally, the GitHubConnector 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.
Supporting Types
GitHubOrg, GitHubOrgArgs
Package Details
- Repository
- dex kotaicode/pulumi-dex
- License
