structs

package
v0.1.31 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 24, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// VCSProviderAzureDevOps represents Azure DevOps VCS provider.
	VCSProviderAzureDevOps = "AZURE_DEVOPS"

	// VCSProviderBitbucketDatacenter represents Bitbucket Datacenter
	// (self-hosted) VCS provider.
	VCSProviderBitbucketDatacenter = "BITBUCKET_DATACENTER"

	// VCSProviderBitbucketCloud represents Bitbucket Cloud (managed) VCS
	// provider.
	VCSProviderBitbucketCloud = "BITBUCKET_CLOUD"

	// VCSProviderGitHubEnterprise represents GitHub Enterprise (self-hosted)
	// VCS provider.
	VCSProviderGitHubEnterprise = "GITHUB_ENTERPRISE"

	// VCSProviderGitlab represents GitLab VCS provider.
	VCSProviderGitlab = "GITLAB"

	// VCSProviderShowcases represents the showcases provider.
	VCSProviderShowcases = "SHOWCASE"
)
View Source
const StackConfigVendorAnsible = "StackConfigVendorAnsible"

StackConfigVendorAnsible is a graphql union typename.

View Source
const StackConfigVendorCloudFormation = "StackConfigVendorCloudFormation"

StackConfigVendorCloudFormation is a graphql union typename.

View Source
const StackConfigVendorKubernetes = "StackConfigVendorKubernetes"

StackConfigVendorKubernetes is a graphql union typename.

View Source
const StackConfigVendorPulumi = "StackConfigVendorPulumi"

StackConfigVendorPulumi is a graphql union typename.

View Source
const StackConfigVendorTerraform = "StackConfigVendorTerraform"

StackConfigVendorTerraform is a graphql union typename.

Variables

This section is empty.

Functions

func PopulateDeleteStackSchedule added in v0.1.28

func PopulateDeleteStackSchedule(d *schema.ResourceData, sd *ScheduledStackDelete) error

func PopulateTaskSchedule added in v0.1.28

func PopulateTaskSchedule(d *schema.ResourceData, t *ScheduledTask) error

Types

type AWSIntegration added in v0.1.20

type AWSIntegration struct {
	ID                          string   `graphql:"id"`
	DurationSeconds             int      `graphql:"durationSeconds"`
	GenerateCredentialsInWorker bool     `graphql:"generateCredentialsInWorker"`
	ExternalID                  string   `graphql:"externalId"`
	Labels                      []string `graphql:"labels"`
	Name                        string   `graphql:"name"`
	RoleARN                     string   `graphql:"roleArn"`
	Space                       string   `graphql:"space"`
}

AWSIntegration represents an integration with AWS.

func (*AWSIntegration) PopulateResourceData added in v0.1.20

func (i *AWSIntegration) PopulateResourceData(d *schema.ResourceData)

PopulateResourceData populates Terraform resource data with the contents of the AWSIntegration.

func (*AWSIntegration) ToMap added in v0.1.31

func (i *AWSIntegration) ToMap() map[string]interface{}

type AWSIntegrationAttachment added in v0.1.20

type AWSIntegrationAttachment struct {
	ID       string `graphql:"id"`
	StackID  string `graphql:"stackId"`
	IsModule bool   `graphql:"isModule"`
	Read     bool   `graphql:"read"`
	Write    bool   `graphql:"write"`
}

AWSIntegrationAttachment is a single AWS integration stack or module attachment.

func (*AWSIntegrationAttachment) PopulateResourceData added in v0.1.20

func (i *AWSIntegrationAttachment) PopulateResourceData(d *schema.ResourceData)

PopulateResourceData populates Terraform resource data with the contents of the AWSIntegration attachment.

type AnsibleInput added in v0.1.19

type AnsibleInput struct {
	Playbook graphql.String `json:"playbook"`
}

AnsibleInput represents Ansible-specific configuration.

type AzureIntegration added in v0.1.8

type AzureIntegration struct {
	ID                    string   `graphql:"id"`
	AdminConsentProvided  bool     `graphql:"adminConsentProvided"`
	AdminConsentURL       string   `graphql:"adminConsentURL"`
	ApplicationID         string   `graphql:"applicationId"`
	DefaultSubscriptionID *string  `graphql:"defaultSubscriptionId"`
	DisplayName           string   `graphql:"displayName"`
	Labels                []string `graphql:"labels"`
	Name                  string   `graphql:"name"`
	TenantID              string   `graphql:"tenantId"`
	Space                 string   `graphql:"space"`
}

AzureIntegration represents an Azure identity provided by the Spacelift integration.

func (*AzureIntegration) PopulateResourceData added in v0.1.8

func (i *AzureIntegration) PopulateResourceData(d *schema.ResourceData)

PopulateResourceData populates Terraform resource data with the contents of the AzureIntegration.

func (*AzureIntegration) ToMap added in v0.1.31

func (i *AzureIntegration) ToMap() map[string]interface{}

type AzureIntegrationAttachment added in v0.1.8

type AzureIntegrationAttachment struct {
	ID             string  `graphql:"id"`
	StackID        string  `graphql:"stackId"`
	IsModule       bool    `graphql:"isModule"`
	Read           bool    `graphql:"read"`
	SubscriptionID *string `graphql:"subscriptionId"`
	Write          bool    `graphql:"write"`
}

AzureIntegrationAttachment is a single Azure integration stack or module attachment.

func (*AzureIntegrationAttachment) PopulateResourceData added in v0.1.8

func (i *AzureIntegrationAttachment) PopulateResourceData(d *schema.ResourceData)

PopulateResourceData populates Terraform resource data with the contents of the AzureIntegration attachment.

type CloudFormationInput

type CloudFormationInput struct {
	EntryTemplateFile graphql.String `json:"entryTemplateFile"`
	Region            graphql.String `json:"region"`
	StackName         graphql.String `json:"stackName"`
	TemplateBucket    graphql.String `json:"templateBucket"`
}

CloudFormationInput represents CloudFormation-specific configuration.

type ConfigElement

type ConfigElement struct {
	ID        string
	Checksum  string
	Type      ConfigType
	Value     *string
	WriteOnly bool
}

ConfigElement represents a single configuration element.

type ConfigInput

type ConfigInput struct {
	ID        graphql.ID      `json:"id"`
	Type      ConfigType      `json:"type"`
	Value     graphql.String  `json:"value"`
	WriteOnly graphql.Boolean `json:"writeOnly"`
}

ConfigInput represents the input required to create or update a config element.

type ConfigType

type ConfigType string

ConfigType is a type of configuration element.

type Context

type Context struct {
	ID          string   `graphql:"id"`
	Description *string  `graphql:"description"`
	Labels      []string `graphql:"labels"`
	Name        string   `graphql:"name"`
	Space       string   `graphql:"space"`
}

Context represents the Context data relevant to the provider.

type ContextAttachment

type ContextAttachment struct {
	ID       string `graphql:"id"`
	StackID  string `graphql:"stackId"`
	IsModule bool   `graphql:"isModule"`
	Priority int    `graphql:"priority"`
}

ContextAttachment is a single context attachment embedded in a Context.

type DriftDetectionIntegrationInput added in v0.0.5

type DriftDetectionIntegrationInput struct {
	Reconcile graphql.Boolean  `json:"reconcile"`
	Schedule  []graphql.String `json:"schedule"`
	Timezone  *graphql.String  `json:"timezone"`
}

DriftDetectionIntegrationInput represents the input required to create or update a drift detection integration.

type Integrations

type Integrations struct {
	AWS struct {
		AssumedRoleARN              *string `graphql:"assumedRoleArn"`
		AssumeRolePolicyStatement   string  `graphql:"assumeRolePolicyStatement"`
		ExternalID                  *string `graphql:"externalID"`
		GenerateCredentialsInWorker bool    `graphql:"generateCredentialsInWorker"`
		DurationSeconds             *int    `graphql:"durationSeconds"`
	} `graphql:"aws"`
	DriftDetection struct {
		Reconcile bool     `graphql:"reconcile"`
		Schedule  []string `graphql:"schedule"`
		Timezone  string   `graphql:"timezone"`
	} `graphql:"driftDetection"`
	GCP struct {
		ServiceAccountEmail *string  `graphql:"serviceAccountEmail"`
		TokenScopes         []string `graphql:"tokenScopes"`
	} `graphql:"gcp"`
	Webhooks []struct {
		ID       string `graphql:"id"`
		Enabled  bool   `graphql:"enabled"`
		Endpoint string `graphql:"endpoint"`
		Secret   string `graphql:"secret"`
	} `graphql:"webhooks"`
}

Integrations represents external integrations for a Stack and a Module.

type KubernetesInput added in v0.1.12

type KubernetesInput struct {
	Namespace graphql.String `json:"namespace"`
}

KubernetesInput represents Kubernetes-specific configuration.

type Module

type Module struct {
	ID                  string       `graphql:"id"`
	Administrative      bool         `graphql:"administrative"`
	Branch              string       `graphql:"branch"`
	Description         *string      `graphql:"description"`
	Integrations        Integrations `graphql:"integrations"`
	Labels              []string     `graphql:"labels"`
	Name                string       `graphql:"name"`
	Namespace           string       `graphql:"namespace"`
	ProjectRoot         *string      `graphql:"projectRoot"`
	ProtectFromDeletion bool         `graphql:"protectFromDeletion"`
	Provider            string       `graphql:"provider"`
	Repository          string       `graphql:"repository"`
	SharedAccounts      []string     `graphql:"sharedAccounts"`
	Space               string       `graphql:"space"`
	TerraformProvider   string       `graphql:"terraformProvider"`
	WorkerPool          *struct {
		ID string `graphql:"id"`
	} `graphql:"workerPool"`
}

Module represents the Module data relevant to the provider.

func (*Module) ExportVCSSettings added in v0.1.9

func (m *Module) ExportVCSSettings(d *schema.ResourceData) error

ExportVCSSettings exports VCS settings into Terraform schema.

type ModuleCreateInput

type ModuleCreateInput struct {
	UpdateInput       ModuleUpdateInput `json:"updateInput"`
	Name              *graphql.String   `json:"name"`
	Namespace         *graphql.String   `json:"namespace"`
	Provider          *graphql.String   `json:"provider"`
	Repository        graphql.String    `json:"repository"`
	TerraformProvider *graphql.String   `json:"terraformProvider"`
	Space             *graphql.String   `json:"space"`
}

ModuleCreateInput represents the input required to create a Module.

type ModuleUpdateInput

type ModuleUpdateInput struct {
	Administrative      graphql.Boolean   `json:"administrative"`
	Branch              graphql.String    `json:"branch"`
	Description         *graphql.String   `json:"description"`
	Labels              *[]graphql.String `json:"labels"`
	ProjectRoot         *graphql.String   `json:"projectRoot"`
	ProtectFromDeletion graphql.Boolean   `json:"protectFromDeletion"`
	SharedAccounts      *[]graphql.String `json:"sharedAccounts"`
	WorkerPool          *graphql.ID       `json:"workerPool"`
	Space               *graphql.String   `json:"space"`
}

ModuleUpdateInput represents the input required to update a Module.

type ModuleUpdateV2Input added in v0.1.28

type ModuleUpdateV2Input struct {
	Administrative      graphql.Boolean   `json:"administrative"`
	Branch              graphql.String    `json:"branch"`
	Description         *graphql.String   `json:"description"`
	Labels              *[]graphql.String `json:"labels"`
	Namespace           *graphql.String   `json:"namespace"`
	ProjectRoot         *graphql.String   `json:"projectRoot"`
	ProtectFromDeletion graphql.Boolean   `json:"protectFromDeletion"`
	Provider            *graphql.String   `json:"provider"`
	Repository          graphql.String    `json:"repository"`
	SharedAccounts      *[]graphql.String `json:"sharedAccounts"`
	Space               *graphql.String   `json:"space"`
	WorkerPool          *graphql.ID       `json:"workerPool"`
}

ModuleUpdateV2Input represents the input required to update a Module, including the source.

type Policy

type Policy struct {
	ID     string   `graphql:"id"`
	Labels []string `graphql:"labels"`
	Name   string   `graphql:"name"`
	Body   string   `graphql:"body"`
	Type   string   `graphql:"type"`
	Space  string   `graphql:"space"`
}

Policy represents Policy data relevant to the provider.

type PolicyAttachment

type PolicyAttachment struct {
	ID       string `graphql:"id"`
	StackID  string `graphql:"stackId"`
	IsModule bool   `graphql:"isModule"`
}

PolicyAttachment is a single policy attachment embedded in a Policy.

type PolicyType

type PolicyType string

PolicyType represents a policy type.

type PulumiInput

type PulumiInput struct {
	LoginURL  graphql.String `json:"loginURL"`
	StackName graphql.String `json:"stackName"`
}

PulumiInput represents Pulumi-specific configuration.

type ScheduledDeleteInput added in v0.1.28

type ScheduledDeleteInput struct {
	ShouldDeleteResources graphql.Boolean `json:"shouldDeleteResources"`
	TimestampSchedule     *graphql.Int    `json:"timestampSchedule"`
}

ScheduledDeleteInput represents the input for creating/updating a scheduled stack_delete.

type ScheduledStackDelete added in v0.1.28

type ScheduledStackDelete struct {
	ID                    string
	ShouldDeleteResources graphql.Boolean `json:"shouldDeleteResources"`
	TimestampSchedule     graphql.Int     `json:"timestampSchedule"`
}

ScheduledStackDelete represents a scheduled delete.

type ScheduledTask added in v0.1.28

type ScheduledTask struct {
	ID                string           `json:"id"`
	Command           graphql.String   `json:"command"`
	CronSchedule      []graphql.String `json:"cronSchedule"`
	TimestampSchedule graphql.Int      `json:"timestampSchedule"`
	Timezone          *graphql.String  `json:"timezone"`
}

ScheduledTask represents a scheduled task.

type ScheduledTaskInput added in v0.1.28

type ScheduledTaskInput struct {
	Command           graphql.String   `json:"command"`
	CronSchedule      []graphql.String `json:"cronSchedule"`
	TimestampSchedule *graphql.Int     `json:"timestampSchedule"`
	Timezone          *graphql.String  `json:"timezone"`
}

ScheduledTaskInput represents the input for creating/updating a scheduled task.

type Space added in v0.1.21

type Space struct {
	ID              string   `graphql:"id"`
	Description     string   `graphql:"description"`
	Name            string   `graphql:"name"`
	InheritEntities bool     `graphql:"inheritEntities"`
	ParentSpace     *string  `graphql:"parentSpace"`
	Labels          []string `graphql:"labels"`
}

Space represents the Space data relevant to the provider.

type SpaceInput added in v0.1.21

type SpaceInput struct {
	Description     graphql.String    `json:"description"`
	Name            graphql.String    `json:"name"`
	InheritEntities graphql.Boolean   `json:"inheritEntities"`
	ParentSpace     graphql.ID        `json:"parentSpace"`
	Labels          *[]graphql.String `json:"labels"`
}

SpaceInput represents input relevant to creating or updating the Space.

type Stack

type Stack struct {
	ID                  string        `graphql:"id"`
	Administrative      bool          `graphql:"administrative"`
	AfterApply          []string      `graphql:"afterApply"`
	AfterDestroy        []string      `graphql:"afterDestroy"`
	AfterInit           []string      `graphql:"afterInit"`
	AfterPerform        []string      `graphql:"afterPerform"`
	AfterPlan           []string      `graphql:"afterPlan"`
	Autodeploy          bool          `graphql:"autodeploy"`
	Autoretry           bool          `graphql:"autoretry"`
	BeforeApply         []string      `graphql:"beforeApply"`
	BeforeDestroy       []string      `graphql:"beforeDestroy"`
	BeforeInit          []string      `graphql:"beforeInit"`
	BeforePerform       []string      `graphql:"beforePerform"`
	BeforePlan          []string      `graphql:"beforePlan"`
	Branch              string        `graphql:"branch"`
	Deleting            bool          `graphql:"deleting"`
	Description         *string       `graphql:"description"`
	GitHubActionDeploy  bool          `graphql:"githubActionDeploy"`
	Integrations        *Integrations `graphql:"integrations"`
	Labels              []string      `graphql:"labels"`
	LocalPreviewEnabled bool          `graphql:"localPreviewEnabled"`
	ManagesStateFile    bool          `graphql:"managesStateFile"`
	Name                string        `graphql:"name"`
	Namespace           string        `graphql:"namespace"`
	ProjectRoot         *string       `graphql:"projectRoot"`
	ProtectFromDeletion bool          `graphql:"protectFromDeletion"`
	Provider            string        `graphql:"provider"`
	Repository          string        `graphql:"repository"`
	RunnerImage         *string       `graphql:"runnerImage"`
	Space               string        `graphql:"space"`
	TerraformVersion    *string       `graphql:"terraformVersion"`
	VendorConfig        struct {
		Typename string `graphql:"__typename"`
		Ansible  struct {
			Playbook string `graphql:"playbook"`
		} `graphql:"... on StackConfigVendorAnsible"`
		CloudFormation struct {
			EntryTemplateName string `graphql:"entryTemplateFile"`
			Region            string `graphql:"region"`
			StackName         string `graphql:"stackName"`
			TemplateBucket    string `graphql:"templateBucket"`
		} `graphql:"... on StackConfigVendorCloudFormation"`
		Kubernetes struct {
			Namespace string `graphql:"namespace"`
		} `graphql:"... on StackConfigVendorKubernetes"`
		Pulumi struct {
			LoginURL  string `graphql:"loginURL"`
			StackName string `graphql:"stackName"`
		} `graphql:"... on StackConfigVendorPulumi"`
		Terraform struct {
			UseSmartSanitization bool    `graphql:"useSmartSanitization"`
			Version              *string `graphql:"version"`
			Workspace            *string `graphql:"workspace"`
		} `graphql:"... on StackConfigVendorTerraform"`
	} `graphql:"vendorConfig"`
	WorkerPool *struct {
		ID string `graphql:"id"`
	} `graphql:"workerPool"`
}

Stack represents the Stack data relevant to the provider.

func (*Stack) ExportVCSSettings added in v0.1.9

func (s *Stack) ExportVCSSettings(d *schema.ResourceData) error

ExportVCSSettings exports VCS settings into Terraform schema.

type StackDependency added in v0.1.27

type StackDependency struct {
	ID               string `graphql:"id"`
	StackID          string `graphql:"stackId"`
	DependsOnStackID string `graphql:"dependsOnStackId"`
}

type StackDependencyInput added in v0.1.27

type StackDependencyInput struct {
	StackID          graphql.ID `json:"stackId"`
	DependsOnStackID graphql.ID `json:"dependsOnStackId"`
}

type StackInput

type StackInput struct {
	Administrative      graphql.Boolean    `json:"administrative"`
	AfterApply          *[]graphql.String  `json:"afterApply"`
	AfterDestroy        *[]graphql.String  `json:"afterDestroy"`
	AfterInit           *[]graphql.String  `json:"afterInit"`
	AfterPerform        *[]graphql.String  `json:"afterPerform"`
	AfterPlan           *[]graphql.String  `json:"afterPlan"`
	Autodeploy          graphql.Boolean    `json:"autodeploy"`
	Autoretry           graphql.Boolean    `json:"autoretry"`
	BeforeApply         *[]graphql.String  `json:"beforeApply"`
	BeforeDestroy       *[]graphql.String  `json:"beforeDestroy"`
	BeforeInit          *[]graphql.String  `json:"beforeInit"`
	BeforePerform       *[]graphql.String  `json:"beforePerform"`
	BeforePlan          *[]graphql.String  `json:"beforePlan"`
	Branch              graphql.String     `json:"branch"`
	Description         *graphql.String    `json:"description"`
	GitHubActionDeploy  graphql.Boolean    `json:"githubActionDeploy"`
	Labels              *[]graphql.String  `json:"labels"`
	LocalPreviewEnabled graphql.Boolean    `json:"localPreviewEnabled"`
	Name                graphql.String     `json:"name"`
	Namespace           *graphql.String    `json:"namespace"`
	ProjectRoot         *graphql.String    `json:"projectRoot"`
	ProtectFromDeletion graphql.Boolean    `json:"protectFromDeletion"`
	Provider            *graphql.String    `json:"provider"`
	Repository          graphql.String     `json:"repository"`
	RunnerImage         *graphql.String    `json:"runnerImage"`
	Space               *graphql.String    `json:"space"`
	VendorConfig        *VendorConfigInput `json:"vendorConfig"`
	WorkerPool          *graphql.ID        `json:"workerPool"`
}

StackInput represents the input required to create or update a Stack.

type TerraformInput

type TerraformInput struct {
	UseSmartSanitization *graphql.Boolean `json:"useSmartSanitization"`
	Version              *graphql.String  `json:"version"`
	Workspace            *graphql.String  `json:"workspace"`
}

TerraformInput represents Terraform-specific configuration.

type VCSAgentPool added in v0.1.6

type VCSAgentPool struct {
	ID          string  `graphql:"id"`
	Config      *string `graphql:"config"`
	Description *string `graphql:"description"`
	Name        string  `graphql:"name"`
}

VCSAgentPool represents the VCS Agent Pool data relevant to the provider.

type VendorConfigInput

type VendorConfigInput struct {
	AnsibleInput        *AnsibleInput        `json:"ansible"`
	CloudFormationInput *CloudFormationInput `json:"cloudFormation"`
	Kubernetes          *KubernetesInput     `json:"kubernetes"`
	Pulumi              *PulumiInput         `json:"pulumi"`
	Terraform           *TerraformInput      `json:"terraform"`
}

VendorConfigInput represents vendor-specific configuration.

type WebhooksIntegrationInput

type WebhooksIntegrationInput struct {
	Enabled  graphql.Boolean `json:"enabled"`
	Endpoint graphql.String  `json:"endpoint"`
	Secret   graphql.String  `json:"secret"`
}

WebhooksIntegrationInput represents the input required to create or update a webhook.

type WorkerPool

type WorkerPool struct {
	ID          string   `graphql:"id"`
	Config      string   `graphql:"config"`
	Name        string   `graphql:"name"`
	Description *string  `graphql:"description"`
	Labels      []string `graphql:"labels"`
	Space       string   `graphql:"space"`
}

WorkerPool represents the WorkerPool data relevant to the provider.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL